build: userspace: No merge globals
Add a compiler option to not merge globals. gen_kobject_list.py is not capable of distinguish addresses of merged objects. The script itself does not look wrong. The dward specification says that the attribute DW_AT_location with opcode DW_OP_addr encodes a machine address and whose size is the size of an address on the target machine but for merged objects the address is longer, not clear why. Disable global merge when userspace is enabled to avoid this problem. Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
This commit is contained in:
parent
43781ba2a0
commit
ac5d45a080
5 changed files with 15 additions and 0 deletions
|
@ -388,6 +388,10 @@ include(cmake/extra_flags.cmake)
|
|||
|
||||
zephyr_cc_option(-fno-asynchronous-unwind-tables)
|
||||
|
||||
if(CONFIG_USERSPACE)
|
||||
zephyr_compile_options($<TARGET_PROPERTY:compiler,no_global_merge>)
|
||||
endif()
|
||||
|
||||
if(CONFIG_THREAD_LOCAL_STORAGE)
|
||||
# Only support local exec TLS model at this point.
|
||||
zephyr_cc_option(-ftls-model=local-exec)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue