Message164818
> If we're worrying about undefined behaviour, it looks like recent optimizations have *introduced* new undefined behaviour in the form of strict aliasing violations. E.g., from ascii_decode:
>
> unsigned long value = *(const unsigned long *) _p;
>
> (here _p has type const char *).
I don't see what the undefined behavior. Can you specify exactly the
item of the Standard, in which it is mentioned?
> This should really be fixed; compilers are known to make optimizations based on the assumption that this sort of undefined behaviour doesn't occur.
I don't know how else you can rewrite it, without destroying completely
the effect of optimization.
In any case, I don't think that the original patch introduces some new
undefined behavior. |
|
Date |
User |
Action |
Args |
2012-07-07 10:49:59 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, mark.dickinson, pitrou |
2012-07-07 10:49:58 | serhiy.storchaka | link | issue15144 messages |
2012-07-07 10:49:58 | serhiy.storchaka | create | |
|