Skip to content

Conversation

@dcpleung
Copy link
Member

@dcpleung dcpleung commented Jan 8, 2021

This adds kconfigs and compiler flags to support MMX and SSE* instructions.

@github-actions github-actions bot added area: API Changes to public APIs area: Documentation area: Kernel area: Tests Issues related to a particular existing or missing test area: X86 x86 Architecture (32-bit) labels Jan 8, 2021
Copy link
Contributor

@andrewboie andrewboie Jan 8, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is CONFIG_X86_SSE supposed to be a superset of all the configs like CONFIG_X86_SSE4A, for example?

Most of the asm code related to SSE applies to all SSE variants and also MMX since they are all using the same set of XMM registers

I don't think this will work if someone just selects CONFIG_X86_SSE4 for example

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed to do select X86_SSE so CONFIG_X86_SSE is enabled when any SSE kconfig is enabled.

MMX registers overlay with FPU registers so only needs CONFIG_FPU.

@zephyrbot zephyrbot requested a review from ceolin January 8, 2021 21:10
@dcpleung dcpleung force-pushed the x86_sse_kconfigs branch 3 times, most recently from 95d70b0 to 5157746 Compare January 13, 2021 23:44
It is possible to enable SSE without using SSE for floating
point, so fix the compiler flags.

Signed-off-by: Daniel Leung <[email protected]>
On x86, it is possible to use FPU (387) and SSE for floating
point operations. So test both.

Signed-off-by: Daniel Leung <[email protected]>
The app_kernel benchmarking app has the config file for benchmarking
with floating point enabled, but it was never used. So add it
to the testcase.yaml.

Note that this also limits to run on one CPU on a SMP system as
the resulting numbers would be more consistent among runs.

Signed-off-by: Daniel Leung <[email protected]>
This adds X86 keyword to the kconfigs to indicate these are
for x86. The old options are still there marked as
deprecated.

Signed-off-by: Daniel Leung <[email protected]>
This adds kconfigs and compiler flags to support MMX and SSE*
instructions.

Signed-off-by: Daniel Leung <[email protected]>
@nashif nashif added this to the v2.6.0 milestone Jan 28, 2021
@nashif nashif merged commit 5c64992 into zephyrproject-rtos:master Feb 15, 2021
@dcpleung dcpleung deleted the x86_sse_kconfigs branch February 16, 2021 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: API Changes to public APIs area: Documentation area: Kernel area: Tests Issues related to a particular existing or missing test area: X86 x86 Architecture (32-bit)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants