Piotr Wyderski wrote:
> Trying to work-around PR40269 (which doesn't happen
> anymore on trunk, so you may close it) I've commented
> out the dllexport/dllimport section:
> 
>     #define BASE_DLLEXPORT          /*__declspec(dllexport)*/
>     #define BASE_DLLIMPORT          /*__declspec(dllimport)*/
> 
> Then the program compiled successfully, emitting a lot
> of auto-import warning messages, but crashed unexpectedly
> somewhere in the middle of execution. If these __declspecs
> are uncommented, then it works correctly, as expected. Is
> it a known auto-import bug or "feature" I should be aware of,
> or should I dig deeper into the subject and ask out a debbugger
> for a passionate afternoon session?

  You deleted correct code, ignored all the warnings, and got a crashing
executable.  Is that a bug?  I can't be sure without seeing your full
testcase, but I'd guess not.  Auto-import is something of a best-effort
last-resort fallback.  It cannot handle everything that properly annotating
the source code can handle.

  See the section of the ld manual documenting `--enable-auto-import' for the
full and gory details.  Does passing --enable-runtime-pseudo-reloc to the
linker help any in this case?

    cheers,
      DaveK

Reply via email to