> >+ /* NULL memory accesses terminates BB. These accesses are known > >+ to trip undefined behaviour. gimple-ssa-isolate-paths turns them > >+ to volatile accesses and adds builtin_trap call which would > >+ confuse us otherwise. */ > >+ if (infer_nonnull_range_by_dereference (gsi_stmt (si), > >+ null_pointer_node)) > > Does that correctly handle flag_delete_null_pointer_checks and address spaces > with null?
Yes it does both - it is also same check that gimple-ssa-isolate-paths eventually uses to add the trap so we would probably see PRs if it did not. Honza