]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
predicates.md (flash_operand): New predicate.
authorGeorg-Johann Lay <gjl@gcc.gnu.org>
Thu, 4 Oct 2012 17:02:27 +0000 (17:02 +0000)
committerGeorg-Johann Lay <gjl@gcc.gnu.org>
Thu, 4 Oct 2012 17:02:27 +0000 (17:02 +0000)
* config/avr/predicates.md (flash_operand): New predicate.
* config/avr/avr.md (reload_in<mode>): Use it in operand 1 instead
of memory_operand.

From-SVN: r192090

gcc/ChangeLog
gcc/config/avr/avr.md
gcc/config/avr/predicates.md

index 191165604b9ed92b7a3beca73a40914e91777dd2..abdd91721316a929faa62b4e4dbc2bef45d2e141 100644 (file)
@@ -1,3 +1,9 @@
+2012-10-04  Georg-Johann Lay  <avr@gjlay.de>
+
+       * config/avr/predicates.md (flash_operand): New predicate.
+       * config/avr/avr.md (reload_in<mode>): Use it in operand 1 instead
+       of memory_operand.
+
 2012-10-04  Tobias Burnus  <burnus@net-b.de>
 
        * gcc.c (record_temp_file, add_sysrooted_prefix, process_command,
 
 2012-10-03  Andrew W. Nosenko <andrew.w.nosenko@gmail.com>
 
-       *  config/i386/driver-i386.c (host_detect_local_cpu): Fix logic
+       * config/i386/driver-i386.c (host_detect_local_cpu): Fix logic
        in SSE and YMM state support check for -march=native.
 
 2012-10-03  Nick Clifton  <nickc@redhat.com>
 2012-10-02  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR target/54741
-       *  config/i386/driver-i386.c (XCR_XFEATURE_ENABLED_MASK): New.
+       * config/i386/driver-i386.c (XCR_XFEATURE_ENABLED_MASK): New.
        (XSTATE_FP): Likewise.
        (XSTATE_SSE): Likewise.
        (XSTATE_YMM): Likewise.
index 284860e9ec58e54ea6354b9ae63b949bc0a72598..d3ffd1aba4112b94d5007962597c8bd199821c67 100644 (file)
 ;; Secondary input reload from non-generic 16-bit address spaces
 (define_insn "reload_in<mode>"
   [(set (match_operand:MOVMODE 0 "register_operand"   "=r")
-        (match_operand:MOVMODE 1 "memory_operand"      "m"))
+        (match_operand:MOVMODE 1 "flash_operand"       "m"))
    (clobber (match_operand:QI 2 "d_register_operand"  "=d"))]
   ;; Fixme: The insn condition must not test the address space.
   ;;   Because the gen tools refuse to generate insns for address spaces
index 04587ae491f2528f17055e21b2ac2a6a41670cf2..fc4ca03de6bc90f8b47630234f7433671f54b8ed 100644 (file)
        (not (match_test "avr_load_libgcc_p (op)"))
        (not (match_test "avr_mem_memx_p (op)"))))
 
+;; Return 1 if OP is a memory operand in one of the __flash* address spaces
+(define_predicate "flash_operand"
+  (and (match_operand 0 "memory_operand")
+       (match_test "Pmode == mode")
+       (ior (match_test "!MEM_P (op)")
+            (match_test "avr_mem_flash_p (op)"))))
+
 ;; Return 1 if OP is the zero constant for MODE.
 (define_predicate "const0_operand"
   (and (match_code "const_int,const_fixed,const_double")