This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Patch: clear NEXT_INSN, PREV_INSN and JUMP_LABEL on deleted insns


On 9/5/07, Laurynas Biveinis <laurynas.biveinis@gmail.com> wrote:
> Hello,
>
> This cleanup patch changes remove_insn to clear NEXT_INSN, PREV_INSN,
> and if applicable, JUMP_LABEL fields on the deleted insn. This exposed
> several places where these insn fields were in fact accessed after the
> insn was deleted and this patch fixes them all, in a sense completing
> transition to FOR_BB_INSNS_SAFE.
>
> The motivation for this change is general cleanliness and also the
> fact, that some GC implementations (e.g. Boehm's GC) put inaccessible
> objects on the free lists without cleaning them and later tries to
> mark them. Also, it is a little step towards being able to do GC
> collection at arbitrary points.
>
> It is quite possible that my testing did not detect all the places
> where the fields are accessed after deletion and thus breaks
> something. Luckily, any such places should be easy to fix.
>
> The patch seems larger than it is because of necessary indentation
> changes. Bootstrapped/regtested on i686-pc-linux-gnu. OK for mainline?

FYI this patch has caused at least PR33351 on i686 and from hearsay
similar problems on other architectures.  Looks like you missed to
update some places?

Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]