From 9fac6184c49f0e6f62b71627150856a020dc9a40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=B7=D0=B4=D0=B0=D0=B9=D1=89=D0=B8=D0=BA?= Date: Mon, 5 Mar 2018 19:22:40 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9D=D1=8E=D0=B0=D0=BD=D1=81=D1=8B=20=D0=BF?= =?UTF-8?q?=D1=80=D0=BE=D1=84=D0=B8=D0=BB=D0=B8=D1=80=D0=BE=D0=B2=D1=89?= =?UTF-8?q?=D0=B8=D0=BA=D0=B0=20=D0=B8=C2=A0=D0=BD=D0=B5=D0=BA=D0=BE=D1=82?= =?UTF-8?q?=D0=BE=D1=80=D1=8B=D0=B5=20=D0=B4=D1=80=D1=83=D0=B3=D0=B8=D0=B5?= =?UTF-8?q?=20=D0=BD=D1=8E=D0=B0=D0=BD=D1=81=D1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/compiler/HighLevelRASL-Condition.sref | 5 ++++- src/compiler/HighLevelRASL.sref | 2 +- src/compiler/Opcodes.sref | 1 + src/srlib/refalrts.cpp | 14 ++++++++++++-- 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/src/compiler/HighLevelRASL-Condition.sref b/src/compiler/HighLevelRASL-Condition.sref index 0f70ed72..938cd62b 100644 --- a/src/compiler/HighLevelRASL-Condition.sref +++ b/src/compiler/HighLevelRASL-Condition.sref @@ -65,7 +65,10 @@ $ENTRY SentenceTail{ ) : e.CmdSentenceCommands - = e.CondResultCommands e.CmdSentenceCommands + = e.CondResultCommands + (#CmdProfilerStopSentence) + (#CmdProfileFunction) + e.CmdSentenceCommands : e.SentenceCommands = s.StackTop e.SentenceCommands; diff --git a/src/compiler/HighLevelRASL.sref b/src/compiler/HighLevelRASL.sref index 80d8b38d..b84ab2b1 100644 --- a/src/compiler/HighLevelRASL.sref +++ b/src/compiler/HighLevelRASL.sref @@ -46,7 +46,7 @@ $ENTRY HighLevelRASL { ((e.Pattern) e.Conditions (e.Result)) = link_info == right_bracket); + // TODO: проверить после завершения разработки условий + //assert(left_bracket->link_info == right_bracket); if (next(function) != right_bracket) { res_first = next(function); @@ -2007,7 +2008,16 @@ int refalrts::profiler::reverse_compare( void refalrts::profiler::start_generated_function() { clock_t now = clock(); - refalrts_profiler_assert_eq(g_current_state, cInRuntime); + // TODO: проверить после завершения разработки условий + //refalrts_profiler_assert_eq(g_current_state, cInRuntime); + switch (g_current_state) { + case cInRuntime: + case cInResultLinear: + break; + + default: + refalrts_switch_default_violation(g_current_state); + } g_counters[cCounter_RuntimeTime] += (now - g_prev_cutoff); g_prev_cutoff = now; g_current_state = cInPatternLinear;