summaryrefslogtreecommitdiff
path: root/decoder
diff options
context:
space:
mode:
authorgraehl@gmail.com <graehl@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-08-04 06:45:36 +0000
committergraehl@gmail.com <graehl@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-08-04 06:45:36 +0000
commit93049316b48a5c2e856e4087ff71241c94544d28 (patch)
treea02b6c8efc47798e12f0c6949f8a19b8bf9619ef /decoder
parent71ac846dabc26010b5af11f93868042d6f34cc8d (diff)
alloca note
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@476 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder')
-rwxr-xr-xdecoder/ff_lm_fsa.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/decoder/ff_lm_fsa.h b/decoder/ff_lm_fsa.h
index df11ab18..b95fde02 100755
--- a/decoder/ff_lm_fsa.h
+++ b/decoder/ff_lm_fsa.h
@@ -53,7 +53,7 @@ struct LanguageModelFsa : public FsaFeatureFunctionBase<LanguageModelFsa> {
}
//variable length array is in C99, msvc++, if it doesn't support it, #ifdef it or use a stackalloc call (forget the name)
if (ctxlen_) {
- WordID ctx[ngram_order_];
+ WordID ctx[ngram_order_]; //alloca if you don't have C99
state_copy(ctx,old_st);
ctx[ctxlen_]=TD::none; // make this part of state? wastes space but saves copies.
Featval p=floored(pimpl_->WordProb(w,ctx));