[Avida-SVN] r2488 - in development: Avida.xcodeproj source/script
brysonda at myxo.css.msu.edu
brysonda at myxo.css.msu.edu
Sat Mar 22 18:59:14 PDT 2008
Author: brysonda
Date: 2008-03-22 21:59:14 -0400 (Sat, 22 Mar 2008)
New Revision: 2488
Modified:
development/Avida.xcodeproj/project.pbxproj
development/source/script/cDirectInterpretASTVisitor.cc
development/source/script/cParser.cc
development/source/script/cSemanticASTVisitor.cc
Log:
AS:
Fix recursive function call stack pointer handling.
Modified: development/Avida.xcodeproj/project.pbxproj
===================================================================
--- development/Avida.xcodeproj/project.pbxproj 2008-03-21 22:52:00 UTC (rev 2487)
+++ development/Avida.xcodeproj/project.pbxproj 2008-03-23 01:59:14 UTC (rev 2488)
@@ -2457,7 +2457,7 @@
isa = XCBuildConfiguration;
buildSettings = {
COPY_PHASE_STRIP = NO;
- DEBUG_INFORMATION_FORMAT = stabs;
+ DEBUG_INFORMATION_FORMAT = dwarf;
DEPLOYMENT_POSTPROCESSING = NO;
GCC_ALTIVEC_EXTENSIONS = YES;
GCC_AUTO_VECTORIZATION = YES;
Modified: development/source/script/cDirectInterpretASTVisitor.cc
===================================================================
--- development/source/script/cDirectInterpretASTVisitor.cc 2008-03-21 22:52:00 UTC (rev 2487)
+++ development/source/script/cDirectInterpretASTVisitor.cc 2008-03-23 01:59:14 UTC (rev 2488)
@@ -1158,7 +1158,8 @@
// Set current scope to the function symbol table
cSymbolTable* func_symtbl = func_src_symtbl->GetFunctionSymbolTable(fun_id);
- int sp = m_sp + prev_symtbl->GetNumVariables();
+ int o_sp = m_sp;
+ int sp = m_call_stack.GetSize();
m_call_stack.Resize(m_call_stack.GetSize() + func_symtbl->GetNumVariables());
for (int i = 0; i < func_symtbl->GetNumVariables(); i++) {
switch (func_symtbl->GetVariableType(i).type) {
@@ -1255,7 +1256,7 @@
// Restore previous scope
m_has_returned = false;
m_call_stack.Resize(m_call_stack.GetSize() - m_cur_symtbl->GetNumVariables());
- m_sp -= prev_symtbl->GetNumVariables();
+ m_sp = o_sp;
m_cur_symtbl = prev_symtbl;
}
}
Modified: development/source/script/cParser.cc
===================================================================
--- development/source/script/cParser.cc 2008-03-21 22:52:00 UTC (rev 2487)
+++ development/source/script/cParser.cc 2008-03-23 01:59:14 UTC (rev 2488)
@@ -188,7 +188,7 @@
*/
#ifndef DEBUG_AS_PARSER
-#define DEBUG_AS_PARSER 1
+#define DEBUG_AS_PARSER 0
#endif
#if DEBUG_AS_PARSER
Modified: development/source/script/cSemanticASTVisitor.cc
===================================================================
--- development/source/script/cSemanticASTVisitor.cc 2008-03-21 22:52:00 UTC (rev 2487)
+++ development/source/script/cSemanticASTVisitor.cc 2008-03-23 01:59:14 UTC (rev 2488)
@@ -33,7 +33,7 @@
#ifndef DEBUG_AS_SEMANTIC
-#define DEBUG_AS_SEMANTIC 1
+#define DEBUG_AS_SEMANTIC 0
#endif
#define SEMANTIC_ERROR(code, ...) reportError(AS_SEMANTIC_ERR_ ## code, node.GetFilePosition(), __LINE__, ##__VA_ARGS__)
More information about the Avida-cvs
mailing list