  int
  ix86_decompose_address (rtx addr, struct ix86_address *out)
  {
-@@ -8757,7 +8843,18 @@
+@@ -8757,7 +8874,18 @@
    enum ix86_address_seg seg = SEG_DEFAULT;
  
    if (REG_P (addr) || GET_CODE (addr) == SUBREG)

     {
       /* This symbol may be referenced via a displacement from the PIC
 	 base address (@GOTOFF).  */
@@ -9573,14 +9724,14 @@
 	addr = XEXP (addr, 0);
       if (GET_CODE (addr) == PLUS)
 	  {

 /* IPA Passes */
 extern struct ipa_opt_pass pass_ipa_inline;
 extern struct ipa_opt_pass pass_ipa_cp;
diff -uNr gcc-4.4.2.orig/gcc/varasm.c gcc-4.4.2/gcc/varasm.c
--- gcc-4.4.2.orig/gcc/varasm.c	2009-03-17 20:18:21.000000000 +0000
+++ gcc-4.4.2/gcc/varasm.c	2009-12-16 23:59:29.000000000 +0000
@@ -5623,6 +5623,9 @@
     kind = TLS_MODEL_GLOBAL_DYNAMIC;
   if (kind < flag_tls_default)
     kind = flag_tls_default;
+  if (TARGET_64BIT && flag_control_integrity)
+    /* NaCl currently supports a hybrid TLS model: __tls_get_addr(TPOFF) */
+    kind = TLS_MODEL_LOCAL_EXEC;
 
   return kind;
 }
diff -uNr gcc-4.4.2.orig/libgcc/config.host gcc-4.4.2/libgcc/config.host
--- gcc-4.4.2.orig/libgcc/config.host	2009-04-17 13:58:41.000000000 +0200
+++ gcc-4.4.2/libgcc/config.host	2009-11-26 18:14:17.000000000 +0100
