aboutsummaryrefslogtreecommitdiff
path: root/src/interp/c-util.boot
AgeCommit message (Collapse)AuthorFilesLines
2011-02-24more cleanupsdos-reis1-8/+11
2011-02-24 * interp/c-util.boot (isSimple): Accept constructor instantiations.dos-reis1-3/+3
* algebra/formula.spad.pamphlet: Avoid Lispisms. * algebra/mathml.spad.pamphlet: Likewise. * algebra/op.spad.pamphlet: Likewise. * algebra/sex.spad.pamphlet: Likewise.
2011-02-14 * interp/compiler.boot (getUnionMode): Remove.dos-reis1-1/+27
(isUnionMode): Move to c-util.boot. (coerceExtraHard): Rework. (belongsTo?): Remove. * interp/c-util.boot (isUnionMode): Moved from compiler.boot. (unionLike?): New. (unionProperty): Likewise. (getInverseEnvironment): Use unionProperty instead of getUnionMode.
2011-02-14 * interp/c-util.boot (getSuccessEnvironment): Follow throughdos-reis1-0/+4
temporaries designating result of assignment. (getInverseEnvironment): Likewise.
2011-02-08 * interp/category.boot(categoryObject?): Rename from isCategory. dos-reis1-1/+1
* interp/c-util.boot: Adjust use. * interp/functor.boot: Likewise. * interp/modemap.boot: Likewise.
2011-02-07 * interp/c-util.boot (matchingEXIT): New.dos-reis1-0/+8
(simplifySEQ): Use it.
2011-02-06 * interp/g-opt.boot ($VMsideEffectFreeOperators): Include %fmanexp.dos-reis1-2/+7
(sideEffectFree?): New. (varIsAssigned): Tidy. (canInlineVarDefinition): Likewise. * interp/boot-pkg.lisp (gensym?): New. * interp/c-util.boot ($NonExpandableOperators): New. (expandableDefinition?): Use it. * algebra/sf.spad.pamphlet (DoubleFloat): Use %fmanexp.
2011-02-04 * interp/c-util.boot (mutateConditionalFormWithUnaryFunction):dos-reis1-16/+16
Rename from mutateCONDFormWithUnaryFunction. Update callers (mutateBindingFormWithUnaryFunction): Rename from mutateLETFormWithUnaryFunction. Allow %bind form too. Update callers.
2011-02-03 * interp/c-util.boot: Replace COND with %when throught.dos-reis1-4/+4
Use %otherwise instead of %true where appropriate. * interp/define.boot: Likewise. * interp/functor.boot: Likewise. * interp/g-opt.boot: Likewise. * interp/i-code.boot: Likewise. * interp/i-output.boot: Likewise. * interp/i-spec1.boot: Likewise. * interp/i-spec2.boot: Likewise. * interp/i-util.boot: Likewise. * interp/info.boot: Likewise. * interp/modemap.boot: Likewise. * interp/nruncomp.boot: Likewise. * interp/pspad1.boot: Likewise. * interp/pspad2.boot: Likewise. * interp/slam.boot: Likewise. * interp/wi1.boot: Likewise. * interp/wi2.boot: Likewise. * interp/compiler.boot (canReturn): Don't test for COND anymore.
2011-01-27Generate SVREF for simple vector slot refs.dos-reis1-6/+5
2011-01-19 * interp/vmlisp.lisp (FIXP): Remove.dos-reis1-6/+6
* interp/alql.boot: Use integer? instead of FIXP. * interp/br-con.boot: Likewise. * interp/br-op1.boot: Likewise. * interp/c-util.boot: Likewise. * interp/fnewmeta.lisp: Likewise. * interp/ht-root.boot: Likewise. * interp/i-analy.boot: Likewise. * interp/i-syscmd.boot: Likewise. * interp/i-toplev.boot: Likewise. * interp/interop.boot: Likewise. * interp/lisplib.boot: Likewise. * interp/mark.boot: Likewise. * interp/newfort.boot: Likewise. * interp/nrunfast.boot: Likewise. * interp/pspad1.boot: Likewise. * interp/setvars.boot: Likewise. * interp/showimp.boot: Likewise. * interp/slam.boot: Likewise. * interp/topics.boot: Likewise. * interp/trace.boot: Likewise. * interp/wi1.boot: Likewise. * interp/wi2.boot: Likewise. * interp/word.boot: Likewise.
2010-12-30more string cleanupsdos-reis1-6/+10
2010-12-28Character constants clean updos-reis1-4/+5
2010-12-12More clean up on string vs symbol confusionsdos-reis1-10/+10
2010-12-12Clean symbol vs. character vs. string confusiondos-reis1-3/+3
2010-10-28 * interp/c-util.boot: Cleanup.dos-reis1-109/+11
2010-10-27 * interp/c-util.boot (makeCommonEnvironment): Use list node pointerdos-reis1-5/+5
comparaison, not object comparaison.
2010-09-07 * interp/c-util.boot (massageBackendCode): Remove conditional ondos-reis1-7/+11
$NEWSPAD since it always true. Keep note of Lisp-level special variable even if it is set with SETQ. (transformToBackendCode): Declare special variables before fluid and local variables. * interp/compiler.boot: Don't compile SETQ forms as if they were Spad codes.
2010-07-29 * interp/c-util.boot (removeToplevelRETURN_-FROM): New.dos-reis1-1/+11
(transformToBackendCode): Use it to clean function body.
2010-07-27 * interp/types.boot (%Code): Include %Char.dos-reis1-11/+11
* interp/c-util.boot (middleEndExpand): Temporarilty Comment out signature.
2010-07-27Misc cleanupdos-reis1-14/+14
2010-07-25 * interp/c-util.boot (usedSymbol?): Move to g-util.boot.dos-reis1-14/+0
* interp/nruncomp.boot (NRTsetVector4a): Tidy.
2010-07-18More cleanupsdos-reis1-2/+2
2010-07-01 * interp/define.boot (registerInlinableDomain): New.dos-reis1-10/+5
(compAdd): Use it to promote base domains for inlining. * interp/c-util.boot (lookupFunctionInstance): Foeld into lookupDefiningFunction. Remove. (lookupDefiningFunction): Evaluate only system domains to avoid cycles.
2010-06-30 * interp/c-util.boot (giveVariableSomeValue): New.dos-reis1-0/+7
* interp/compiler.boot (setqMultiple): Use it. (compColon): Likewise. (compRetractGuard): Likewise. (compRecoverDomain): Likewise. (defineMatchScrutinee): Likewise. (compStepIterator): Likewise. (compIterator): Likewise. (compUnnamedMapping): Likewise. * interp/define.boot (giveFormalParametersValues): Likewise. * interp/wi1.boot (setqMultiple): Likewise. * interp/wi2.boot (compIterator): Likewise. (smallIntegerStep): Likewise.
2010-06-30 * interp/c-util.boot (getRepresentation): Tidy.dos-reis1-1/+2
* interp/define.boot (checkRepresentation): Don't compile the base domain here yet.
2010-06-25 * interp/c-util.boot (expandableDefinition?): Try to make it ados-reis1-1/+3
forwarding function if possible.
2010-06-24 * interp/c-util.boot: Cleanup.dos-reis1-1/+1
* interp/compiler.boot: Likewise. * interp/functor.boot: Likewise. * interp/g-opt.boot: Likewise. * interp/mark.boot: Likewise. * interp/nrunfast.boot: Likewise. * interp/wi1.boot: Likewise. * interp/wi2.boot: Likewise.
2010-06-23 * interp/nruncomp.boot (optDeltaEntry): Don't optimize currentdos-reis1-2/+2
domain modemap references here. * interp/g-opt.boot ($VMsideEffectFreeOperators): Include more floating point operators. ($simpleVMoperators): Move FUNCALL here. (isVMConstantForm): Tidy. * interp/g-util.boot: Expand more floating point insns. * interp/c-util.boot (replaceSimpleFunctions): Replace more constants. * algebra/integer.spad.pamphlet (Integer): More cleanup. Use builtin functions. * algebra/sf.spad.pamphlet: Likewise.
2010-06-22 Group sequence of LETT definitions into LET/LET* expressions wheredos-reis1-2/+4
appropriate. * interp/g-opt.boot (jumpToToplevel?): New. (singleAssignment?): Likewise. (groupVariableDefinitions): Likewise. Use them. (optimizeFunctionDef): Group toplevel variable definitions into a bind expression. * interp/g-util.boot (expandBind): Tidy. * interp/c-util.boot (transformToBackendCode): Refrain from enclosing let-expressions in SEQ if not needed.
2010-06-21 * interp/c-util.boot (middleEndExpand): Give it another macrodos-reis1-1/+2
expansion pass after new opcode expansion.
2010-06-20 * boot/tokens.boot (readOnly?): New builtin Boot function.dos-reis1-4/+5
* interp/c-util.boot (isLispSpecialVariable): Tidy. (transformToBackendCode): Likewise.
2010-06-07 * interp/c-util.boot (isLispSpecialVariable): New.dos-reis1-3/+14
(mutateToBackendCode): Use it to record special vars. Be careful with locally bound variables.
2010-06-06 * interp/c-util.boot (mutateToBackendCode): Don't replace explicitdos-reis1-1/+1
SETQ by LETT.
2010-06-06 * interp/c-util.boot (needPROGS?): New.dos-reis1-1/+11
(transformToBackendCode): Use it. Don't add unneeded PROG/RETURN.
2010-06-04 * interp/br-con.boot: More cleanup.dos-reis1-3/+3
* interp/br-op1.boot: Likewise. * interp/br-saturn.boot: Likewise. * interp/c-util.boot: Likewise. * interp/category.boot: Likewise. * interp/clam.boot: Likewise. * interp/database.boot: Likewise. * interp/functor.boot: Likewise. * interp/g-cndata.boot: Likewise. * interp/g-util.boot: Likewise. * interp/guess.boot: Likewise. * interp/i-coerce.boot: Likewise. * interp/i-funsel.boot: Likewise. * interp/i-intern.boot: Likewise. * interp/i-syscmd.boot: Likewise. * interp/interop.boot: Likewise. * interp/newfort.boot: Likewise. * interp/nruncomp.boot: Likewise. * interp/nrunfast.boot: Likewise. * interp/nrunopt.boot: Likewise. * interp/setvars.boot: Likewise. * interp/slam.boot: Likewise. * interp/topics.boot: Likewise.
2010-06-03 * interp/buildom.boot: Cleanup.dos-reis1-0/+4
* interp/c-util.boot ($SetCategory): New constant. * interp/compiler.boot: Use it. * interp/functor.boot: Likewise.
2010-06-02 * interp/c-util.boot (usedSymbol?): New.dos-reis1-6/+27
(declareUnusedParameters): Use it. Reimplement. * interp/i-map.boot (compileCoerceMap): Adjust call. * interp/i-spec1.boot (compileADEFBody): Likewise. (mkIterFun): Likewise. * interp/slam.boot (reportFunctionCompilation): Likewise. (reportFunctionCacheAll): Likewise. (compileRecurrenceRelation): Likewise.
2010-05-30 * interp/c-util.boot (middleEndExpand): Tidy.dos-reis1-3/+2
* interp/g-util.boot (expandToVMForm): Likewise. (expandStore): Refine store to pair components. * algebra/any.spad.pamphlet (Scope): Use builtin operators. (Environment): Likewise. * algebra/domain.spad.pamphlet (FunctionDescriptor): Likewise. (ConstructorCall): Likewise. (FunctorData): Likewise. (OperatorSignature): Likewise. (Category): Likewise. (Domain): Likewise. * algebra/integer.spad.pamphlet (Integer): Likewise. (NonNegativeInteger): Likewise. * algebra/outform.spad.pamphlet: Likewise. * algebra/si.spad.pamphlet (SingleInteger): Likewise. * algebra/syntax.spad.pamphlet (Syntax): Likewise.
2010-05-30Add more opcodesdos-reis1-0/+1
2010-05-29 * interp/compiler.boot (getExternalSymbolMode): Allow Lisp asdos-reis1-0/+2
foreign language. (checkExternalEntity): Likewise. (compSignatureImport): Likewise. Give foreign variables dummy values. * interp/c-util.boot (middleEndExpand): Handle %true and %false. * interp/g-util.boot (expandToVMForm): Likewise.
2010-05-28Clean up MAKEPROP usesdos-reis1-1/+1
2010-05-27 * interp/sys-macros.lisp (eval): Expand opcodes before calling EVAL.dos-reis1-2/+2
* interp/slam.boot (reportFunctionCompilation): Tidy. Take extra care when generating code that access global variables. (reportFunctionCacheAll): Likewise. * interp/i-util.boot (isLocallyBound): Define. * interp/i-spec1.boot (upCOLLECT1): Bind $iteratorVars to nil. (upLoopIterSTEP): Call mkIteratorVariable instead of mkLocalVar. (upLoopIterIN): Likewise. (upStreamIterIN): Likewise. (upStreamIterSTEP): Likewise. (collectOneStream): Tidy. (mkAndApplyPredicates): Likewise. (mkIterFun): Lose last parameter. Tidy. (declare): Use isLocallyBound. (getAndEvalConstructorArgument): Likewise. (mkIteratorVariable): New. ($iteratorVars): New. * interp/i-spec2.boot (upREPEAT1): Bind $iteratorVars to nil. (isLocalPred): Use isLocallyBound. (compileIs): Likewise. (evalLETput): Likewise. (evalLETchangeValue): Likewise. (isType): Likewise. * interp/i-analy.boot (bottomUp): Likewise. (bottomUpDefaultCompile): Likewise. * interp/i-eval.boot (evalForm): Likewise. (getMappingArgValue): Likewise. * interp/i-map.boot (findLocalVars1): Likewise. (findLocalsInLoop): Tidy. Filter out iterator variables. (isLocalVar): Remove. * interp/g-util.boot (mkCacheName): Define here. (mkAuxiliaryName): Likewise. * interp/c-util.boot (backendCompileSLAM): Use mkCacheName. (backendCompileSPADSLAM): Likewise. * interp/clam.boot (compClam): Likewise. (clearCategoryCaches): Likewise. (clearCategoryCache): Likewise. * interp/g-timer.boot (timedEVALFUN): expandToVMForm is now implicitly called by eval.
2010-05-26 * boot/tokens.boot: Automatically translate alphabetic?, digit?,dos-reis1-2/+2
lowerCase?, upperCase?, readByte, readInteger, readLine, writeByte, writeLine. * interp/as.boot: Use them. * interp/bc-matrix.boot: Likewise. * interp/bc-solve.boot: Likewise. * interp/br-con.boot: Likewise. * interp/br-search.boot: Likewise. * interp/br-util.boot: Likewise. * interp/c-doc.boot: Likewise. * interp/c-util.boot: Likewise. * interp/database.boot: Likewise. * interp/format.boot: Likewise. * interp/fortcall.boot: Likewise. * interp/functor.boot: Likewise. * interp/g-util.boot: Likewise. * interp/guess.boot: Likewise. * interp/ht-root.boot: Likewise. * interp/htcheck.boot: Likewise. * interp/htsetvar.boot: Likewise. * interp/i-map.boot: Likewise. * interp/i-output.boot: Likewise. * interp/i-syscmd.boot: Likewise. * interp/i-util.boot: Likewise. * interp/int-top.boot: Likewise. * interp/intfile.boot: Likewise. * interp/mark.boot: Likewise. * interp/msgdb.boot: Likewise. * interp/pf2sex.boot: Likewise. * interp/pspad1.boot: Likewise. * interp/pspad2.boot: Likewise. * interp/scan.boot: Likewise. * interp/slam.boot: Likewise. * interp/sys-utility.boot: Likewise. * interp/topics.boot: Likewise. * interp/trace.boot: Likewise. * interp/word.boot: Likewise.
2010-05-26 * interp/c-util.boot ($ClearBodyToken): New constant.dos-reis1-0/+4
* interp/define.boot (compDefineCapsuleFunction): Use it in place of special character. (spadCompileOrSetq): Likewise. * interp/i-map.boot (addMap): Likewise. (getUserIdentifiersIn): Likewise. * interp/wi1.boot (spadCompileOrSetq): Likewise.
2010-05-25 * interp/g-util.boot: Add expanders for %lt, %le, %gt, %ge, %not,dos-reis1-0/+8
%and, %or, and %bind forms. * interp/c-util.boot (mutateToBackendCode): Handle LET and LET* forms. * interp/nrungo.boot (NRTisRecurrenceRelation): Move to ... * interp/slam.boot: Here. Remove NRT prefix. (compileRecurrenceRelation): Generate forms using middle-end opcodes.
2010-05-25 * interp/g-util.boot: Implement expansion of %collect forms.dos-reis1-1/+1
* interp/c-util.boot (middleEndExpand): Tidy. * interp/g-opt.boot (changeThrowToExit): Don't look into %collect forms. * interp/i-map.boot (getUserIdentifiersIn): Factorize. Handle %collect forms same as COLLECT forms. (findLocalVars1): Likewise. * interp/i-spec1.boot (evalCOLLECT): Now generate %collect forms. (checkForFreeVariables): Factorize. Handle %collect forms same as COLLECT forms.
2010-05-25 * interp/g-util.boot (expandToVMForm): New. Export.dos-reis1-9/+1
(getOpcodeExpander): move to here from c-util.boot. ($middleEndOpcodes): Likewise.
2010-05-24Fix typodos-reis1-1/+1
2010-05-24 * interp/c-util.boot ($middleEndOpcodes): New.dos-reis1-5/+14
(getOpcodeExpander): Likewise. (middleEndExpand): Use it to expand middle end opcodes.