10851 want sys/linker_set.h

Review Request #1788 — Created April 25, 2019 and submitted

tsoome
illumos-gate
10851
1789
c668ff0...
general
10851 want sys/linker_set.h


  • 0
  • 0
  • 0
  • 1
  • 1
Description From Last Updated
gwr
  1. The issue doesn't say much about what this is, and why one would want it.
    Nor does the review show a consumer that might show an example usage.
    Can you answer those? (What is this? Why do you want it?)
    What can this do that you can't with existing linker scripts?

    1. Ill update the issue. But to have the question answered - I did create the separate review to keep the discussions separate for header and consumers. From my point the first consumer would be https://illumos.org/rb/r/1789/. Note, the ld linker set support update did add elf tests which we also can update to use this header. Afaik the next consumer could be bhyve.

      If nothing else will pop up, I assume I would need to push this and ficl update together.

    2. After a look at the other RB, it appears this is anohter way to construct a sort of "export table" for an object?
      I'm curious why we're not using one of the existing practices for this, i.e. how kernel modules do it?

    3. Not just another way, but used much. We would like to have it so we would not need to rewrite things. Besides, linker sets is simple and elegant mechanism and is supported by many platforms for a long time.

  2. 
      
tsoome
domag02
  1. 
      
  2. usr/src/uts/common/sys/linker_set.h (Diff revision 2)
     
     

    To scope a preprocessor macro into a limited region:

    #undef  __MAKE_SET
    
    1. My fault, just "Ship it!"
  3. 
      
tsoome
tsoome
Review request changed

Status: Closed (submitted)

Loading...