Mercurial > hg > CbC > CbC_gcc
comparison gcc/store-motion.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 84e7813d76e9 |
children |
comparison
equal
deleted
inserted
replaced
131:84e7813d76e9 | 145:1830386684a0 |
---|---|
1 /* Store motion via Lazy Code Motion on the reverse CFG. | 1 /* Store motion via Lazy Code Motion on the reverse CFG. |
2 Copyright (C) 1997-2018 Free Software Foundation, Inc. | 2 Copyright (C) 1997-2020 Free Software Foundation, Inc. |
3 | 3 |
4 This file is part of GCC. | 4 This file is part of GCC. |
5 | 5 |
6 GCC is free software; you can redistribute it and/or modify it under | 6 GCC is free software; you can redistribute it and/or modify it under |
7 the terms of the GNU General Public License as published by the Free | 7 the terms of the GNU General Public License as published by the Free |
910 struct st_expr *smexpr) | 910 struct st_expr *smexpr) |
911 { | 911 { |
912 rtx_insn *insn; | 912 rtx_insn *insn; |
913 rtx mem, note, set; | 913 rtx mem, note, set; |
914 | 914 |
915 mem = smexpr->pattern; | 915 insn = prepare_copy_insn (reg, SET_SRC (single_set (del))); |
916 insn = gen_move_insn (reg, SET_SRC (single_set (del))); | |
917 | 916 |
918 unsigned int i; | 917 unsigned int i; |
919 rtx_insn *temp; | 918 rtx_insn *temp; |
920 FOR_EACH_VEC_ELT_REVERSE (smexpr->antic_stores, i, temp) | 919 FOR_EACH_VEC_ELT_REVERSE (smexpr->antic_stores, i, temp) |
921 if (temp == del) | 920 if (temp == del) |
944 delete_insn (del); | 943 delete_insn (del); |
945 | 944 |
946 /* Now we must handle REG_EQUAL notes whose contents is equal to the mem; | 945 /* Now we must handle REG_EQUAL notes whose contents is equal to the mem; |
947 they are no longer accurate provided that they are reached by this | 946 they are no longer accurate provided that they are reached by this |
948 definition, so drop them. */ | 947 definition, so drop them. */ |
948 mem = smexpr->pattern; | |
949 for (; insn != NEXT_INSN (BB_END (bb)); insn = NEXT_INSN (insn)) | 949 for (; insn != NEXT_INSN (BB_END (bb)); insn = NEXT_INSN (insn)) |
950 if (NONDEBUG_INSN_P (insn)) | 950 if (NONDEBUG_INSN_P (insn)) |
951 { | 951 { |
952 set = single_set (insn); | 952 set = single_set (insn); |
953 if (!set) | 953 if (!set) |