Commit 3fdf63c7 authored by Ilya Edrenkin's avatar Ilya Edrenkin
Browse files

Two small bugfixes: 1) for -DNDEBUG; 2) for CUDA 6.5


git-svn-id: https://svn.code.sf.net/p/kaldi/code/trunk@4351 5e6a8d80-dfce-4ca6-a32a-6e07a63d50c8
parent e3ac7288
...@@ -28,8 +28,7 @@ all: $(LIBFILE) ...@@ -28,8 +28,7 @@ all: $(LIBFILE)
ifeq ($(CUDA), true) ifeq ($(CUDA), true)
#Default compute capability architectures we compile with #Default compute capability architectures we compile with
CUDA_ARCH=-gencode arch=compute_10,code=sm_10 \ CUDA_ARCH=-gencode arch=compute_13,code=sm_13 \
-gencode arch=compute_13,code=sm_13 \
-gencode arch=compute_20,code=sm_20 -gencode arch=compute_20,code=sm_20
#Get the CUDA Toolkit version (remove decimal point char) #Get the CUDA Toolkit version (remove decimal point char)
CUDA_VERSION=$(shell $(CUDATKDIR)/bin/nvcc -V | grep release | sed -e 's|.*release ||' -e 's|,.*||' -e 's|\.||') CUDA_VERSION=$(shell $(CUDATKDIR)/bin/nvcc -V | grep release | sed -e 's|.*release ||' -e 's|,.*||' -e 's|\.||')
...@@ -48,6 +47,11 @@ ifeq ($(CUDA), true) ...@@ -48,6 +47,11 @@ ifeq ($(CUDA), true)
ifeq ($(CUDA_VER_GT_6_0), true) ifeq ($(CUDA_VER_GT_6_0), true)
CUDA_ARCH += -gencode arch=compute_50,code=sm_50 CUDA_ARCH += -gencode arch=compute_50,code=sm_50
endif endif
#For toolkit older than 6.5, add the compute capability 1.0
CUDA_VER_GT_6_5 := $(shell [ $(CUDA_VERSION) -ge 65 ] && echo true)
ifneq ($(CUDA_VER_GT_6_5), true)
CUDA_ARCH += -gencode arch=compute_10,code=sm_10
endif
endif endif
......
...@@ -1387,14 +1387,14 @@ bool DeterminizeLatticePhonePrunedFirstPass( ...@@ -1387,14 +1387,14 @@ bool DeterminizeLatticePhonePrunedFirstPass(
// First, insert the phones. // First, insert the phones.
typename ArcTpl<Weight>::Label first_phone_label = typename ArcTpl<Weight>::Label first_phone_label =
DeterminizeLatticeInsertPhones(trans_model, fst); DeterminizeLatticeInsertPhones(trans_model, fst);
KALDI_ASSERT(TopSort(fst)); TopSort(fst);
// Second, do determinization with phone inserted. // Second, do determinization with phone inserted.
bool ans = DeterminizeLatticePruned<Weight, IntType>(*fst, beam, fst, opts); bool ans = DeterminizeLatticePruned<Weight, IntType>(*fst, beam, fst, opts);
// Finally, remove the inserted phones. // Finally, remove the inserted phones.
DeterminizeLatticeDeletePhones(first_phone_label, fst); DeterminizeLatticeDeletePhones(first_phone_label, fst);
KALDI_ASSERT(TopSort(fst)); TopSort(fst);
return ans; return ans;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment