RFR: JDK-8331732 : [PPC64] Unify and optimize code which converts != 0 to 1 [v17]
Amit Kumar
amitkumar at openjdk.org
Sat Jun 29 02:51:25 UTC 2024
On Fri, 28 Jun 2024 20:37:08 GMT, Suchismith Roy <sroy at openjdk.org> wrote:
>> Build is succeding . And i also did a register check for templateGenerator with this example using normalize_bool(result,false) ,(java -version was not hitting this code). Seems to be working fine.
>
> I think the 2nd value is taken at default.
amitkumar at Amits-MacBook-Pro ~ % cat tt.cpp
#include <iostream>
using namespace std;
void fun(int a, char b = 'a', float c = 10.3);
int main(void) {
fun(10);
fun(10, 103.483);
return 0;
}
void fun(int a, char b, float c) {
}
amitkumar at Amits-MacBook-Pro ~ % g++ tt.cpp
tt.cpp:8:11: warning: implicit conversion from 'double' to 'char' changes value from 103.483 to 103 [-Wliteral-conversion]
fun(10, 103.483);
~~~ ^~~~~~~
1 warning generated.
That's weird!!!
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/19886#discussion_r1659497821
More information about the hotspot-dev
mailing list