gcc 3.4.2 vs &address == NULL

Chris Johns chrisj at rtems.org
Sat Nov 13 00:21:22 UTC 2004


Aaron J. Grier wrote:
> I've been encouraged to bring up another toolchain, and I figured I'd
> try and use peter barada's coldfire-hacked gcc 3.4.2.  I've got it
> compiled up, but ran across an old issue which apparently was never
> resolved:
> 
> http://sources.redhat.com/ml/crossgcc/2004-08/msg00013.html
> 
> in a nutshell, the optimizer on gcc 3.4.2 assumes that the address of a
> variable can't be 0, so it optimizes out any checks.  as pointed out in
> the referenced discussion, this is specifically an issue for
> bsp_pretasking_hook in m68kpretaskinghook.c.
> 
> here's the fix.  (the volatile extern declaration might be overkill.)
> 

Please raise a bug report with this detail and attach the patch.

Thanks for the report.

-- 
  Chris Johns



More information about the users mailing list