x86_64: Fix frame size calculation for 64-bit

Calculate frame size in the same way as calculated in patch
"64bit changes to the stack walker for the Quick ABI"

Change-Id: I8c2458f5973536a84f3fd6ad56167b5cfafa9ab4
Signed-off-by: Dmitry Petrochenko <dmitry.petrochenko@intel.com>
diff --git a/compiler/dex/quick/codegen_util.cc b/compiler/dex/quick/codegen_util.cc
index 3961954..9f84e09 100644
--- a/compiler/dex/quick/codegen_util.cc
+++ b/compiler/dex/quick/codegen_util.cc
@@ -1050,10 +1050,11 @@
 int Mir2Lir::ComputeFrameSize() {
   /* Figure out the frame size */
   static const uint32_t kAlignMask = kStackAlignment - 1;
-  uint32_t size = ((num_core_spills_ + num_fp_spills_ +
-                   1 /* filler word */ + cu_->num_regs + cu_->num_outs)
-                   * sizeof(uint32_t)) +
-                   GetNumBytesForCompilerTempSpillRegion();
+  uint32_t size = num_core_spills_ * GetBytesPerGprSpillLocation(cu_->instruction_set)
+                  + num_fp_spills_ * GetBytesPerFprSpillLocation(cu_->instruction_set)
+                  + sizeof(uint32_t)  // Filler.
+                  + (cu_->num_regs + cu_->num_outs) * sizeof(uint32_t)
+                  + GetNumBytesForCompilerTempSpillRegion();
   /* Align and set */
   return (size + kAlignMask) & ~(kAlignMask);
 }