Files
intel-linux-sgx/sdk/simulation/assembly
Dionna Glaze 4495449cea Localize -O0 to necessary functions
The load_regs assembly function uses its caller's frame pointer.
C/C++ compilers are allowed to make optimizations to their
representation of the stack, and frequently omit the frame pointer.

The functions _EEXIT in t_instructions.cpp and _SE3 in
u_instructions.cpp both call load_regs, and thus should be the only ones
that should be affected by deoptimization.

Even -O0 may omit the frame pointer (indeed we found this to be the case
when compiling with GCC 7.3.0), so this change also makes that requirement
explicit by by means of -fno-omit-frame-pointer.

The analogous attribute for -fno-omit-frame-pointer is not available in
clang, so the clang version of the LOAD_REGS_ATTRIBUTES is simply
[[clang:optnone]].

An added bonus of switching the -O0 flag over to an attribute in source
code is that alternate build tools are easier to port to :)

Signed-off-by: Dionna Glaze <dionnaglaze@google.com>
2018-08-14 08:11:31 -07:00
..
2018-06-26 00:12:15 -04:00
2018-08-14 08:11:31 -07:00
2018-01-19 11:02:56 +08:00
2018-01-19 11:02:56 +08:00