Mercurial > hg > truffle
comparison src/gpu/hsail/vm/hsailKernelArguments.cpp @ 18043:f55f2d400797
Fix some format strings
author | Gilles Duboscq <duboscq@ssw.jku.at> |
---|---|
date | Wed, 15 Oct 2014 20:34:55 +0200 |
parents | 7143d614bb20 |
children |
comparison
equal
deleted
inserted
replaced
18042:3498d73280c8 | 18043:f55f2d400797 |
---|---|
34 while (index < length()) { | 34 while (index < length()) { |
35 oop arg = args()->obj_at(index++); | 35 oop arg = args()->obj_at(index++); |
36 jvalue jValue; | 36 jvalue jValue; |
37 if (arg == NULL) { | 37 if (arg == NULL) { |
38 if (TraceGPUInteraction) { | 38 if (TraceGPUInteraction) { |
39 tty->print_cr("[HSAIL] %s::collectArgs object, _index=%d, value = " PTR_FORMAT " is a %s", argsBuilderName(), index, (void*) arg, "null"); | 39 tty->print_cr("[HSAIL] %s::collectArgs object, _index=%d, value = " PTR_FORMAT " is a %s", argsBuilderName(), index, p2i(arg), "null"); |
40 } | 40 } |
41 recordNullObjectParameter(); | 41 recordNullObjectParameter(); |
42 pushObject(arg); | 42 pushObject(arg); |
43 } else { | 43 } else { |
44 java_lang_boxing_object::get_value(arg, &jValue); | 44 java_lang_boxing_object::get_value(arg, &jValue); |
45 BasicType basic_type = java_lang_boxing_object::basic_type(arg); | 45 BasicType basic_type = java_lang_boxing_object::basic_type(arg); |
46 if (basic_type == T_ILLEGAL && (!(arg->is_array()))) { | 46 if (basic_type == T_ILLEGAL && (!(arg->is_array()))) { |
47 if (TraceGPUInteraction) { | 47 if (TraceGPUInteraction) { |
48 tty->print_cr("[HSAIL] %s::collectArgs object, _index=%d, value = " PTR_FORMAT " is a %s", argsBuilderName(), index, (void*) arg, arg == NULL ? "null" : arg->klass()->external_name()); | 48 tty->print_cr("[HSAIL] %s::collectArgs object, _index=%d, value = " PTR_FORMAT " is a %s", argsBuilderName(), index, p2i(arg), arg == NULL ? "null" : arg->klass()->external_name()); |
49 } | 49 } |
50 pushObject(arg); | 50 pushObject(arg); |
51 } else if (arg->is_array()) { | 51 } else if (arg->is_array()) { |
52 if (TraceGPUInteraction) { | 52 if (TraceGPUInteraction) { |
53 int array_length = ((objArrayOop) arg)->length(); | 53 int array_length = ((objArrayOop) arg)->length(); |
54 tty->print_cr("[HSAIL] %s::collectArgs array, length=%d, _index=%d, value = " PTR_FORMAT, argsBuilderName(), array_length, index, (void*) arg); | 54 tty->print_cr("[HSAIL] %s::collectArgs array, length=%d, _index=%d, value = " PTR_FORMAT, argsBuilderName(), array_length, index, p2i(arg)); |
55 } | 55 } |
56 pushObject(arg); | 56 pushObject(arg); |
57 } else { | 57 } else { |
58 switch (basic_type) { | 58 switch (basic_type) { |
59 case T_INT: | 59 case T_INT: |
62 } | 62 } |
63 pushInt(jValue.i); | 63 pushInt(jValue.i); |
64 break; | 64 break; |
65 case T_LONG: | 65 case T_LONG: |
66 if (TraceGPUInteraction) { | 66 if (TraceGPUInteraction) { |
67 tty->print_cr("[HSAIL] %s::collectArgs, T_LONG _index=%d, value = %d", argsBuilderName(), index, jValue.j); | 67 tty->print_cr("[HSAIL] %s::collectArgs, T_LONG _index=%d, value = " JLONG_FORMAT, argsBuilderName(), index, jValue.j); |
68 } | 68 } |
69 pushLong(jValue.j); | 69 pushLong(jValue.j); |
70 break; | 70 break; |
71 case T_FLOAT: | 71 case T_FLOAT: |
72 if (TraceGPUInteraction) { | 72 if (TraceGPUInteraction) { |
73 tty->print_cr("[HSAIL] %s::collectArgs, T_FLOAT _index=%d, value = %d", argsBuilderName(), index, jValue.f); | 73 tty->print_cr("[HSAIL] %s::collectArgs, T_FLOAT _index=%d, value = %f", argsBuilderName(), index, jValue.f); |
74 } | 74 } |
75 pushFloat(jValue.f); | 75 pushFloat(jValue.f); |
76 break; | 76 break; |
77 case T_DOUBLE: | 77 case T_DOUBLE: |
78 if (TraceGPUInteraction) { | 78 if (TraceGPUInteraction) { |
79 tty->print_cr("[HSAIL] %s::collectArgs, T_DOUBLE _index=%d, value = %d", argsBuilderName(), index, jValue.d); | 79 tty->print_cr("[HSAIL] %s::collectArgs, T_DOUBLE _index=%d, value = %lf", argsBuilderName(), index, jValue.d); |
80 } | 80 } |
81 pushDouble(jValue.d); | 81 pushDouble(jValue.d); |
82 break; | 82 break; |
83 case T_BYTE: | 83 case T_BYTE: |
84 if (TraceGPUInteraction) { | 84 if (TraceGPUInteraction) { |