< prev index next >

src/hotspot/cpu/aarch64/frame_aarch64.cpp

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
  * Copyright (c) 2014, Red Hat Inc. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as

@@ -766,17 +766,15 @@
   internal_pf (nextsp, nextfp, nextpc, -1);
 }
 
 extern "C" void pf(unsigned long sp, unsigned long fp, unsigned long pc,
                    unsigned long bcx, unsigned long thread) {
+  RegisterMap map((JavaThread*)thread, false);
   if (!reg_map) {
-    reg_map = NEW_C_HEAP_OBJ(RegisterMap, mtNone);
-    ::new (reg_map) RegisterMap((JavaThread*)thread, false);
-  } else {
-    *reg_map = RegisterMap((JavaThread*)thread, false);
+    reg_map = (RegisterMap*)os::malloc(sizeof map, mtNone);
   }
-
+  memcpy(reg_map, &map, sizeof map);
   {
     CodeBlob *cb = CodeCache::find_blob((address)pc);
     if (cb && cb->frame_size())
       fp = sp + wordSize * (cb->frame_size() - 2);
   }
< prev index next >