1 /* |
1 /* |
2 * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2003, 2014, 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. |
52 VerificationType* stack = NEW_RESOURCE_ARRAY_IN_THREAD(thr, VerificationType, 1); |
52 VerificationType* stack = NEW_RESOURCE_ARRAY_IN_THREAD(thr, VerificationType, 1); |
53 StackMapFrame* frame = new StackMapFrame(_offset, flags, _locals_size, 0, _max_locals, _max_stack, _locals, stack, _verifier); |
53 StackMapFrame* frame = new StackMapFrame(_offset, flags, _locals_size, 0, _max_locals, _max_stack, _locals, stack, _verifier); |
54 return frame; |
54 return frame; |
55 } |
55 } |
56 |
56 |
57 bool StackMapFrame::has_new_object() const { |
|
58 int32_t i; |
|
59 for (i = 0; i < _max_locals; i++) { |
|
60 if (_locals[i].is_uninitialized()) { |
|
61 return true; |
|
62 } |
|
63 } |
|
64 for (i = 0; i < _stack_size; i++) { |
|
65 if (_stack[i].is_uninitialized()) { |
|
66 return true; |
|
67 } |
|
68 } |
|
69 return false; |
|
70 } |
|
71 |
|
72 void StackMapFrame::initialize_object( |
57 void StackMapFrame::initialize_object( |
73 VerificationType old_object, VerificationType new_object) { |
58 VerificationType old_object, VerificationType new_object) { |
74 int32_t i; |
59 int32_t i; |
75 for (i = 0; i < _max_locals; i++) { |
60 for (i = 0; i < _max_locals; i++) { |
76 if (_locals[i].equals(old_object)) { |
61 if (_locals[i].equals(old_object)) { |