Comments (12)
from cxx-abi.
The current vendor-extended type qualifier for address spaces makes the literal address space part of the <source-name>
, e.g. U4AS16
. I believe that predated proper support for parameterized qualifiers; if we were doing it now, it would probably be U2ASILi16EE
, and that's probably the right pattern to use here.
from cxx-abi.
That is, this should just be "U2ASI" <expression> "E"
.
We should probably document the mangling of the address_space qualifier, since it doesn't follow the standard rule of using the qualifier's source spelling.
from cxx-abi.
If I am following this correctly then would the mangling function change to the following:
void CXXNameMangler::mangleType(const DependentExtAddressSpaceType *T) {
Out << "U2ASI";
mangleExpression(T->getAddrSpaceExpr());
Out << 'E';
}
from cxx-abi.
Yes, except you need to respect the correct ordering of qualifiers, and you may need to worry about qualifier nesting, i.e. whether you have Const(DependentExtAddressSpace(int))
vs. DependentExtAddressSpace(Const(int))
. Please take further discussion of that back to the Clang development lists, however.
from cxx-abi.
@jicama How does GCC mangle address_space? I don't seem to have a copy of GCC for a port that supports a non-generic address space.
from cxx-abi.
from cxx-abi.
FWIW, that's https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69549.
from cxx-abi.
Okay. Do you have any objection to adopting our mangling if you ever decide to implement them? If not, I'll prepare a PR for that.
from cxx-abi.
from cxx-abi.
I've submitted a pull request (#29) documenting the address_space mangling.
from cxx-abi.
Merged that PR, which I believe finishes this issue.
from cxx-abi.
Related Issues (20)
- "Deducing this" mangling HOT 14
- Should std::rethrow_exception be covered by the EH ABI? HOT 2
- Emergency EH buffer is overspecified HOT 6
- Where is the most recent ABI document? HOT 1
- Add `[[trivial_abi]]` attribute
- Lambda POD for the purposes of layout? HOT 2
- Mangling the name of an externally visible lambda in a static data member of a class HOT 1
- Proposal: Include an optional specification for mangling names that reference anonymous symbols HOT 4
- Is it possible to form a pointer-to-data-member with offset -1 using explicit derived-to-base conversions without UB? HOT 3
- unnecessary `E`s after <expression> and mangling collisions between <expression> and <number> HOT 1
- need mangling for lambdas appearing in unevaluated operands within a class body HOT 3
- What does "forbidding the use of function templates" mean? HOT 2
- [C++20] [Modules] Do we need the concept of `key function` for class defined in module purview? HOT 25
- Missing HTML encoding in 2.3.1 Data Member Pointers HOT 2
- Proposal: document or somehow notice __cxa_init_primary_exception HOT 3
- Mangling for C++ pack indexing HOT 1
- Function and function pointer types with vendor calling conventions HOT 2
- Ambiguity in mangling grammar around type qualifiers HOT 8
- Question about section 2.9.4 HOT 4
- Questions About Non-POD Types Data Layout HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cxx-abi.