comparison src/cpu/x86/vm/cppInterpreter_x86.cpp @ 23614:32b682649973 jdk8u75-b04

8132051: Better byte behavior Reviewed-by: coleenp, roland
author kevinw
date Fri, 15 Jan 2016 22:33:15 +0000
parents 0bf37f737702
children
comparison
equal deleted inserted replaced
23613:b374548dcb48 23614:32b682649973
1 /* 1 /*
2 * Copyright (c) 2007, 2013, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
868 __ movl(rdx, 868 __ movl(rdx,
869 Address(rdi, 869 Address(rdi,
870 rdx, 870 rdx,
871 Address::times_ptr, ConstantPoolCache::base_offset() + ConstantPoolCacheEntry::flags_offset())); 871 Address::times_ptr, ConstantPoolCache::base_offset() + ConstantPoolCacheEntry::flags_offset()));
872 872
873 Label notByte, notShort, notChar; 873 Label notByte, notBool, notShort, notChar;
874 const Address field_address (rax, rcx, Address::times_1); 874 const Address field_address (rax, rcx, Address::times_1);
875 875
876 // Need to differentiate between igetfield, agetfield, bgetfield etc. 876 // Need to differentiate between igetfield, agetfield, bgetfield etc.
877 // because they are different sizes. 877 // because they are different sizes.
878 // Use the type from the constant pool cache 878 // Use the type from the constant pool cache
887 __ movptr(rax, field_address); 887 __ movptr(rax, field_address);
888 __ jmp(xreturn_path); 888 __ jmp(xreturn_path);
889 889
890 __ bind(notObj); 890 __ bind(notObj);
891 #endif // _LP64 891 #endif // _LP64
892 __ cmpl(rdx, ztos);
893 __ jcc(Assembler::notEqual, notBool);
894 __ load_signed_byte(rax, field_address);
895 __ jmp(xreturn_path);
896
892 __ cmpl(rdx, btos); 897 __ cmpl(rdx, btos);
893 __ jcc(Assembler::notEqual, notByte); 898 __ jcc(Assembler::notEqual, notByte);
894 __ load_signed_byte(rax, field_address); 899 __ load_signed_byte(rax, field_address);
895 __ jmp(xreturn_path); 900 __ jmp(xreturn_path);
896 901