Viewing profile — pascal_cuoq
pascal_cuoq
HN member- Joined
- Mon, Aug 03, 2009, 1:13 PM UTC
- HN karma
- 1,252
- Public activity
- 306 items
- HN profile
- View on Hacker News ↗
About pascal_cuoq
No profile information was provided.
Recent public activity
-
comment
Comment #30552846
Yes, the first two examples in the article weren't obviously enough undefined for the authors of CIL who wrote the list, apparently.
-
comment
Comment #30552676
This list contains several invalid items mixed with the good ones. It starts: Why does the following code return 0 for most values of x? (This should be easy.) int x; return x == (…
-
comment
Comment #30400986
The sentence you quote is near to the words: “[The C++ standardization committee] WG21 has recently adapted the changes promoted in their document p12363. Generally, C++ goes much …
-
comment
Comment #23634351
You need to look at the disassembly of the generated binary to make sense of this sort of performance variation (paying attention to line cache boundaries for code and data), and e…
- comment
-
comment
Comment #22923119
UBSan does detect and report misaligned pointer accesses in the latest versions of GCC and Clang: https://gcc.godbolt.org/z/xpSbXL
-
comment
Comment #22922778
I have seen it said in another thread that UBSan detects this. If you aren't already using all the sanitizers that come with your {CLang, GCC} compiler, you should! They are great!…
-
comment
Comment #22913480
Please explain to me why you think it is. The clause says: “If the value being stored in an object is read from another object that overlaps in any way the storage of the first obj…
-
comment
Comment #22913379
So the clause about assignment? Thanks, that was helpful.
-
comment
Comment #22913204
1 is not an object, but even if it was one, it would not be an object that overlaps with “* p”. You are interpreting the C standard as if it were a philosophy text. It contains a r…
-
comment
Comment #22913194
This line of J.2 only refers to the already cited 6.5.16.1. You keep quoting this clause as if it applied to any of the assignments in the program being discussed. It doesn't. That…
-
comment
Comment #22911375
6.5.16.1 is the “rule that only apply to “lvalue = lvalue;” assignments and is not relevant here” It does not apply to “lvalue = 1;” or to “lvalue = 2;”, which are the two relevant…
-
comment
Comment #22911118
Could you clarify which clause of the C standard you are referring to when you say “due to aliasing, not due to alignment”? I make sense of the C standard for a living (this is lit…
-
comment
Comment #22911094
I have heard this reaction to this article a lot, but sorry, there is nothing in the C standard that says that objects should not overlap, except a rule that only apply to “lvalue …
-
comment
Comment #22911068
Author here! I am not saying or thinking that there is a problem with GCC. I do think that GCC and Clang would be more useful with an option to make them not assume that every poin…
-
comment
Comment #22872396
That may be the case in C++, but in C infinite loops are allowed as long as the controlling condition is a constant expression (making it clear that the developper intends an infin…
-
comment
Comment #22872245
The problem in practice is that you do not write “hello” and “world” to the destination buffer. You write data that is computed more or less directly from user inputs. Often a mali…
-
comment
Comment #22872081
Oh, that was your question. In this case, the reason why &a + 1 == &b is unspecified is that: - it's generally false—there is no reason for b to be just after a in memory, so these…
-
comment
Comment #22871918
If you wrote down your proposal, which the C committee member Robert Seacord is encouraging you to do here: https://news.ycombinator.com/item?id=22870210 , you would have to think …
-
comment
Comment #22871575
Thanks Dan, I missed this question in the heat of the moment.
-
comment
Comment #22871477
I still want to write at least one sequel to that post, on the theme “Alright, can we make a Friendly C Compiler by disabling the annoying optimizations, then?”. Obviously the peop…
-
comment
Comment #22870678
3. would have to be a new mechanism for variadic functions, that would have to be distinguished in header files from the old mechanism with which it is incompatible. So this propos…
-
comment
Comment #22870537
For what it's worth, I personally like this approach, because there are some cases in which it requires less arithmetic in order to be used correctly. And it lends itself better to…
-
comment
Comment #22869035
Unfortunately I am out of useful information: https://news.ycombinator.com/item?id=22868999 I hope someone will provide the next link.
-
comment
Comment #22868999
If I remember correctly, Chandler was the one writing down the draft for LLVM developers to comment on LLVM-side. Unfortunately, if you Google his name and the relevant keywords, t…