abi Questions
1
Solved
Doubt about data type alignment, I'm learning about alignment now, and I have some questions, so I know double aligns to 4 bytes in linux when compiled with gcc for i386 architecture and so the add...
2
In terms of x86 assembly code anyways. I've been reading about function calls, but still can't fully grasp the need for a base / frame pointer (EBP) along with a stack pointer (ESP).
When we...
1
I'm currently doing a deep-dive into Assembly land, mainly from the perspective of x86_64, C, and System V AMD64, generally targeting Linux.
It's pretty straightforward that the calling convention...
Wolter asked 9/9, 2019 at 19:3
3
I read System V ABI for i386 and AMD64. They are telling that arguments must be rounded to multiple of word size. And i dont understand why.
Here is situation. If you pass 4 char arguments to a fu...
6
In my Flutter application I am trying to generate apk that should work on all the devices whether it is 32 bit or 64 bit.
For that I have put the following lines in my build.gradle file. But it l...
1
Solved
When compiling the following code snippet (clang x86-64 -O3)
std::array<int, 5> test()
{
std::array<int, 5> values {{0, 1, 2, 3, 4}};
return values;
}
It produced the typical assem...
Lassiter asked 19/6, 2019 at 12:56
5
X32 allows one to write programs using 32-bit integers, longs and pointers that run on x86_64 processors. Using X32 has a number of benefits under certain use cases. (X32 is different than X86 or X...
Erymanthus asked 20/9, 2015 at 2:56
2
Solved
If I get a bool variable and set its second bit to 1, then variable evaluates to true and false at the same time. Compile the following code with gcc6.3 with -g option, (gcc-v6.3.0/Linux/RHEL6.0-20...
Asclepius asked 29/5, 2019 at 21:58
4
Solved
I was wondering whether the compiler would use different padding on 32-bit and 64-bit systems, so I wrote the code below in a simple VS2019 C++ console project:
struct Z
{
char s;
__int64 i;
};
...
Dilator asked 30/4, 2019 at 11:38
9
Solved
I am preparing some training materials in C and I want my examples to fit the typical stack model.
What direction does a C stack grow in Linux, Windows, Mac OSX (PPC and x86), Solaris, and most re...
Medical asked 20/3, 2009 at 1:58
1
Solved
I'm compiling C++ programs with gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.11). Everything is fine at compile time.
I then link those programs with a library that was built with gcc v...
1
In some circumstances, we use tags to discriminate between functions. A tag is usually an empty struct:
struct Tag { };
Suppose that I have a function, which uses this tag:
void func(Tag, int a...
Swoon asked 22/3, 2019 at 16:26
3
Solved
I believe I understand how the linux x86-64 ABI uses registers and stack to pass parameters to a function (cf. previous ABI discussion). What I'm confused about is if/what registers are expected to...
Byers asked 2/8, 2013 at 19:22
4
Solved
Following links explain x86-32 system call conventions for both UNIX (BSD flavor) & Linux:
http://www.int80h.org/bsdasm/#system-calls
http://www.freebsd.org/doc/en/books/developers-handbook/x...
Kopple asked 29/3, 2010 at 5:48
1
Solved
I'm planning to migrate from ABI split to App Bundle feature. Currently I'm using this code:
def versionCodesAbi = ['x86': 1, 'x86_64': 2, 'armeabi-v7a': 3, 'arm64-v8a': 4]
splits {
abi {
enab...
Ratcliffe asked 11/2, 2019 at 9:12
4
Solved
I'm new to Unity, I'm trying to integrate Unity game(it has ARcore) into the native Android application.
I'm able to launch unity in a new HelloWorld app but unable to launch in my real app(which...
Alcala asked 22/8, 2018 at 2:27
1
I tried some gcc compilers to see if the default enum size is short (at least one byte, as forced with -fshort-enums) or no-short (at least 4 bytes, as forced with -fno-short-enums):
user@host:~$ ...
1
Solved
PEP 425 explains the compatibility tag format for built python distributions, but does not explain the ABI tag in full detail.
The ABI tag can end with a combination of the letters 'd', 'm', and '...
1
Solved
I'm briefly studying the System V ABI for amd64 / x86-64 architecture, and am curious how it handles return values over 128 bits, where rax and rdx aren't enough.
I wrote the following C code on U...
Respirator asked 3/1, 2019 at 13:8
2
Solved
I'd like to learn D, but I haven't understood well an important thing.
How's the current interoperability status between C++ and D?
I'm sure it's impossible to link to C++ compiled binaries, as ...
Whisky asked 27/11, 2018 at 20:41
3
Solved
I'm curious if marking an existing derived C++ class as final to allow for de-virtualisation optimisations will change ABI when using C++11. My expectation is that it should have no effect as I see...
Irrigate asked 20/11, 2018 at 7:10
8
Solved
When passing argument to main() in a C or C++ application, will argv[0] always be the name of the executable? Or is this just a common convention and not guaranteed to be true 100% of the time?
Kristelkristen asked 12/1, 2010 at 17:31
1
Solved
From the x86-64 psABI:
9.1 C++
For the C++ ABI we will use the IA-64 C++ ABI and instantiate it appropriately.
The current draft of that ABI is available at:
http://mentorembedded.github...
Illbehaved asked 23/11, 2018 at 12:47
1
Solved
I am building a shared library on Linux, which serves as a "plugin" to some software (to be specific, it extends Mathematica).
I find that if I build on Ubuntu 16.04, the resulting library does no...
Lise asked 13/11, 2018 at 14:51
1
Solved
By my understanding of how the availability macros and the -mmacosx-version-min flag works, the following code should fail to compile when targeting OS X 10.10:
#include <Availability.h>
#in...
© 2022 - 2024 — McMap. All rights reserved.