[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-12-02 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D112626#3167520 , @rafaelfranco wrote: > Hey all! Thanks for taking the time to review my patch and writing the > Compiler Explorer examples and everything. I had no idea this was the > essentially the wrong approach to thi

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-12-02 Thread Rafael Franco via Phabricator via cfe-commits
rafaelfranco added a comment. Hey all! Thanks for taking the time to review my patch and writing the Compiler Explorer examples and everything. I had no idea this was the essentially the wrong approach to this, I'd be happy to do a bigger overhaul of the whole builtin if that would make it more

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-12-02 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:2090-2094 +// Variadic functions expect the caller to promote float to double. +if (CanonicalType == Context.FloatTy) { + FieldPtr = + CGF.Builder.CreateFPExt(FieldPtr, CGF.ConvertTy

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-12-02 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:2090-2094 +// Variadic functions expect the caller to promote float to double. +if (CanonicalType == Context.FloatTy) { + FieldPtr = + CGF.Builder.CreateFPExt(FieldPtr, CGF.Conv

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-12-01 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:2090-2094 +// Variadic functions expect the caller to promote float to double. +if (CanonicalType == Context.FloatTy) { + FieldPtr = + CGF.Builder.CreateFPExt(FieldPtr, CGF.ConvertTy

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-11-30 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: paulsemel. aaron.ballman added a subscriber: paulsemel. aaron.ballman added a comment. Adding @paulsemel to the reviewer list as he was the original author of this functionality (I commit on his behalf which is how I showed up on the git blame). ===

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-11-20 Thread Rafael Franco via Phabricator via cfe-commits
rafaelfranco added a comment. I have added John McCall to the reviewers as the CODE_OWNERS.txt file says he's responsible for LLVM IR generation. Also Aaron Ballman, as he wrote the function per git-blame output. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://review

[PATCH] D112626: Convert float to double on __builtin_dump_struct

2021-11-20 Thread Rafael Franco via Phabricator via cfe-commits
rafaelfranco created this revision. rafaelfranco published this revision for review. rafaelfranco added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. This seems to fix the problem. Feedback etc. more than welcome :) Variadic arguments of float type are automat