Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-fms-extensions should implement MSVC's section pragmas (const_seg, data_seg, etc) #19259

Closed
rnk opened this issue Feb 18, 2014 · 4 comments
Closed
Labels
bugzilla Issues migrated from bugzilla clang:frontend Language frontend issues, e.g. anything involving "Sema"

Comments

@rnk
Copy link
Collaborator

rnk commented Feb 18, 2014

Bugzilla Link 18885
Resolution FIXED
Resolved on Aug 11, 2014 11:52
Version unspecified
OS Windows NT
Blocks #14079 #19261
CC @majnemer,@timurrrr

Extended Description

The relevant MSDN docs:
http://msdn.microsoft.com/en-us/library/1dc22465.aspx

The grammar:
#pragma const_seg( [ [ { push | pop}, ] [ identifier, ] ] [ "segment-name" [, "segment-class" ] )

This is important because it's used to register initializers and finalizers similar to attribute((section(".init_array"))) in ELF.

David says that we'll have to extend LLVM IR to encode the section properties such as readonly, executable, initialized, etc.

@rnk
Copy link
Collaborator Author

rnk commented Mar 26, 2014

@rnk
Copy link
Collaborator Author

rnk commented Aug 11, 2014

Warren implemented most of these back in r205810.

I implemented #pragma init_seg in r213593, but the code in Blink turned out to be bogus anyway because it was declaring a const globals without a user-declared constructor. We ended up rewriting the Blink code to use statically initialized const references to some uninitialized storage.

@rnk
Copy link
Collaborator Author

rnk commented Aug 11, 2014

Warren implemented most of these back in r205810.

I implemented #pragma init_seg in r213593, but the code in Blink turned out
to be bogus anyway because it was declaring a const globals without a
user-declared constructor. We ended up rewriting the Blink code to use
statically initialized const references to some uninitialized storage.

Really closing...

@rnk
Copy link
Collaborator Author

rnk commented Nov 26, 2021

mentioned in issue #19261

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 9, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla clang:frontend Language frontend issues, e.g. anything involving "Sema"
Projects
None yet
Development

No branches or pull requests

1 participant