eabi

What does code pattern like .size X,.-X do?

感情迁移 提交于 2020-01-11 09:21:50
问题 My question is about some popular but not well documented code I have found in ARM CORTEX M startup files like this STM32. The 'pattern' is: .size X,.-X ,where X is a symbol or label. I have found this answer and understand how .size directive and dot special symbol work, but still complete line seems to do nothing to me. The result of the operation .-X isn't stored anywhere. Could anybody explain what the line does? 回答1: That is placed at the end of function X, and the size of the function

64 bit / 64 bit remainder finding algorithm on a 32 bit processor?

妖精的绣舞 提交于 2019-12-23 03:14:46
问题 I know that similar questions has been asked in the past, but I have implemented after a long process the algorithm to find the quotient correctly using the division by repeated subtraction method. But I am not able to find out the remainder from this approach. Is there any quick and easy way for finding out remainder in 64bit/64bit division on 32bit processor. To be more precise I am trying to implement ulldiv_t __aeabi_uldivmod( unsigned long long n, unsigned long long d) Referenced in this

64 bit / 64 bit remainder finding algorithm on a 32 bit processor?

馋奶兔 提交于 2019-12-23 03:14:22
问题 I know that similar questions has been asked in the past, but I have implemented after a long process the algorithm to find the quotient correctly using the division by repeated subtraction method. But I am not able to find out the remainder from this approach. Is there any quick and easy way for finding out remainder in 64bit/64bit division on 32bit processor. To be more precise I am trying to implement ulldiv_t __aeabi_uldivmod( unsigned long long n, unsigned long long d) Referenced in this

Source and target have different EABI versions

老子叫甜甜 提交于 2019-12-22 16:37:25
问题 I'm trying to compile a .so file using an ARM toolchain. However I keep getting this error- error: Source object has EABI version 0, but target has EABI version 5 I can't change anything in the tool chain as I have to use the one given. I've never seen this error before. I used this compiler flag - -Wl,--no-warn-mismatch But had to take it out as it broke a lot of other stuff. The compiler flags I'm using are: -fPIC -O2 -marm -march=armv7-a 回答1: Use as -meabi=5 I'm not going to claim I fully

arm gcc toolchain as arm-elf or arm-none-eabi, what is the difference?

99封情书 提交于 2019-12-18 10:01:41
问题 When you build a gcc toolchain there is the possibility to build it as arm-elf or as arm-none-eabi, but what is the difference? I use the eabi today, but that is just since everyone else seem to do that... but since that is a really bad argument, it would be really nice to understand the difference. Note: This toolchain will crosscompile code for Cortex-M3 based mcu:s like the stm32. Thanks Some links : EABI: http://en.wikipedia.org/wiki/Application_binary_interface http://infocenter.arm.com

Conflicting CPU architectures 1/13 when compiling for cortex M4

一个人想着一个人 提交于 2019-12-13 15:42:06
问题 I used to compile my microcontroller code with arm-none-eabi-gcc/arm-none-eabi-g++ and everything worked fine. I use the homebrew Cask gcc-arm-embedded on Mac. Yesterday I updated it and now I get these error messages for every object file at the link stage when I compile for a Cortex M4 architecture (compiles fine with M3): /usr/local/Caskroom/gcc-arm-embedded/6-2017-q1-update/gcc-arm-none-eabi-6-2017-q1-update/bin/../lib/gcc/arm-none-eabi/6.3.1/../../../../arm-none-eabi/bin/ld: error:

What does code pattern like .size X,.-X do?

时光怂恿深爱的人放手 提交于 2019-12-13 02:39:36
问题 My question is about some popular but not well documented code I have found in ARM CORTEX M startup files like this STM32. The 'pattern' is: .size X,.-X ,where X is a symbol or label. I have found this answer and understand how .size directive and dot special symbol work, but still complete line seems to do nothing to me. The result of the operation .-X isn't stored anywhere. Could anybody explain what the line does? 回答1: That is placed at the end of function X, and the size of the function

How to set 2 byte wchar_t output?

血红的双手。 提交于 2019-12-07 09:20:58
问题 The GCC uses a 4-byte wchar_t by default. I can set the option -fshort-wchar to get 2 bytes per wchar_t in the L"string constants" . But when I set the compiler option to my source file I get the famous warning message foo.o uses 2-byte wchar_t yet the output is to use 4-byte wchar_t ; use of wchar_t values across objects may fail Since I really want 2-byte wchar_t I also want the output to use this variant. Is there any linker option to tell it what I want? Edit This warning doesn't inhibit

64 bit / 64 bit remainder finding algorithm on a 32 bit processor?

点点圈 提交于 2019-12-06 16:01:30
I know that similar questions has been asked in the past, but I have implemented after a long process the algorithm to find the quotient correctly using the division by repeated subtraction method. But I am not able to find out the remainder from this approach. Is there any quick and easy way for finding out remainder in 64bit/64bit division on 32bit processor. To be more precise I am trying to implement ulldiv_t __aeabi_uldivmod( unsigned long long n, unsigned long long d) Referenced in this document http://infocenter.arm.com/help/topic/com.arm.doc.ihi0043d/IHI0043D_rtabi.pdf What? If you do

Source and target have different EABI versions

馋奶兔 提交于 2019-12-06 07:30:32
I'm trying to compile a .so file using an ARM toolchain. However I keep getting this error- error: Source object has EABI version 0, but target has EABI version 5 I can't change anything in the tool chain as I have to use the one given. I've never seen this error before. I used this compiler flag - -Wl,--no-warn-mismatch But had to take it out as it broke a lot of other stuff. The compiler flags I'm using are: -fPIC -O2 -marm -march=armv7-a Use as -meabi=5 I'm not going to claim I fully understand it... :-) but it solved the problem. What I was trying to do that failed: assemble with GNU AS