hotspot/src/share/vm/c1/c1_Runtime1.cpp
changeset 17370 59a0620561fa
parent 16611 6807a703dd6b
child 18507 61bfc8995bb3
equal deleted inserted replaced
17367:64c84d620e5c 17370:59a0620561fa
     1 /*
     1 /*
     2  * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 1999, 2013, 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.
  1259   if ((unsigned int) arrayOop(src)->length() < (unsigned int)src_pos + (unsigned int)length) return ac_failed;
  1259   if ((unsigned int) arrayOop(src)->length() < (unsigned int)src_pos + (unsigned int)length) return ac_failed;
  1260   if ((unsigned int) arrayOop(dst)->length() < (unsigned int)dst_pos + (unsigned int)length) return ac_failed;
  1260   if ((unsigned int) arrayOop(dst)->length() < (unsigned int)dst_pos + (unsigned int)length) return ac_failed;
  1261 
  1261 
  1262   if (length == 0) return ac_ok;
  1262   if (length == 0) return ac_ok;
  1263   if (src->is_typeArray()) {
  1263   if (src->is_typeArray()) {
  1264     Klass* const klass_oop = src->klass();
  1264     Klass* klass_oop = src->klass();
  1265     if (klass_oop != dst->klass()) return ac_failed;
  1265     if (klass_oop != dst->klass()) return ac_failed;
  1266     TypeArrayKlass* klass = TypeArrayKlass::cast(klass_oop);
  1266     TypeArrayKlass* klass = TypeArrayKlass::cast(klass_oop);
  1267     const int l2es = klass->log2_element_size();
  1267     const int l2es = klass->log2_element_size();
  1268     const int ihs = klass->array_header_in_bytes() / wordSize;
  1268     const int ihs = klass->array_header_in_bytes() / wordSize;
  1269     char* src_addr = (char*) ((oopDesc**)src + ihs) + (src_pos << l2es);
  1269     char* src_addr = (char*) ((oopDesc**)src + ihs) + (src_pos << l2es);