diff mbox

[AArch64,Committed] Fix symbol classification logic.

Message ID 52EA5F82.9000202@arm.com
State New
Headers show

Commit Message

Marcus Shawcroft Jan. 30, 2014, 2:19 p.m. UTC
Symbol classification logic intended to force symbols to memory in large 
memory model is triggering in appropriately for all memory models, this 
results in an unnecessary level of indirection in generated code.

Regressed aarch64-none-elf, committed.

/Marcus

2014-01-30  Marcus Shawcroft  <marcus.shawcroft@arm.com>

         * config/aarch64/aarch64.c (aarch64_classify_symbol): Fix logic
         for SYMBOL_REF in large memory model.
diff mbox

Patch

diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c
index d3c5cbc..16c51a8 100644
--- a/gcc/config/aarch64/aarch64.c
+++ b/gcc/config/aarch64/aarch64.c
@@ -5400,9 +5400,8 @@  aarch64_classify_symbol (rtx x,
 
   if (GET_CODE (x) == SYMBOL_REF)
     {
-      if (aarch64_cmodel == AARCH64_CMODEL_LARGE
-	  || CONSTANT_POOL_ADDRESS_P (x))
-	return SYMBOL_FORCE_TO_MEM;
+      if (aarch64_cmodel == AARCH64_CMODEL_LARGE)
+	  return SYMBOL_FORCE_TO_MEM;
 
       if (aarch64_tls_symbol_p (x))
 	return aarch64_classify_tls_symbol (x);