[llvm-commits] [llvm-gcc-4.2] r46041 - in /llvm-gcc-4.2/trunk/gcc: config/darwin.h llvm-backend.cpp llvm.h objc/objc-act.c varasm.c

Bill Wendling isanbard at gmail.com
Tue Jan 15 17:24:51 PST 2008


On Jan 15, 2008 5:15 PM, Chris Lattner <sabre at nondot.org> wrote:
> Author: lattner
> Date: Tue Jan 15 19:15:26 2008
> New Revision: 46041
>
> URL: http://llvm.org/viewvc/llvm-project?rev=46041&view=rev
> Log:
> The final ultimate(?) fix for the silly objc .reference thing.  Instead of ignoring
> them, we now queue them up as a file-scope inline asm block.  This allows us to
> emit the same directives as gcc.
>
*crosses fingers*

==============================================================================
> --- llvm-gcc-4.2/trunk/gcc/config/darwin.h (original)
> +++ llvm-gcc-4.2/trunk/gcc/config/darwin.h Tue Jan 15 19:15:26 2008
> @@ -920,7 +920,22 @@
>  #undef  TARGET_ASM_RELOC_RW_MASK
>  #define TARGET_ASM_RELOC_RW_MASK machopic_reloc_rw_mask
>
> -
> +/* LLVM LOCAL begin */
> +#ifdef ENABLE_LLVM
> +#define ASM_DECLARE_UNRESOLVED_REFERENCE(FILE,NAME)                    \
> +    do {                                                               \
> +        if (FILE) {                                                    \
> +           char Buffer[strlen(NAME)+30];                               \
> +           sprintf(Buffer, "\t.lazy_reference %s", NAME);              \

Why do you have this line here?

> +          if (MACHOPIC_INDIRECT)                                       \
> +             sprintf(Buffer, "\t.lazy_reference %s", NAME);            \
> +          else                                                         \
> +             sprintf(Buffer, "\t.reference %s", NAME);                 \
> +          llvm_emit_file_scope_asm(Buffer);                            \
> +        }                                                              \
> +       } while (0)

-bw



More information about the llvm-commits mailing list