Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fixed crash in the alignment kernel, which was (hopefully) casued by …

…'overzealous' use of the __restrict keyword on visual c++.

added/use papara::get_version_string().
  • Loading branch information...
commit 57d37ed3011c752f07cedb7f497ac98b609bdb02 1 parent 424d319
@sim82 authored
View
6 CMakeLists.txt
@@ -17,7 +17,10 @@ endif()
# this is a hack: only add subdirectories if IVYMIKE_INCLUDE is not already set.
# IVYMIKE_INCLUDE is abused as a flag indicating that papara should be build in 'library-only' mode...
-add_subdirectory(ivy_mike)
+
+if( NOT PAPARA_NO_IVYMIKE )
+ add_subdirectory(ivy_mike)
+endif()
# add_subdirectory(genassign_blast)
# ENDIF()
@@ -86,3 +89,4 @@ if( USE_CPP11 )
target_link_libraries(dump_anc_probs ivymike ublas_jama ${BOOST_LIBS} ${SYSDEP_LIBS} PocoFoundation)
endif()
+install_targets( /bin papara )
View
8 papara.cpp
@@ -226,6 +226,11 @@ add_log_sink::~add_log_sink() {
ls_buf.remove_sink(s_);
}
+
+std::string papara::get_version_string() {
+ return std::string( "2.3" );
+}
+
template<typename seq_tag>
queries<seq_tag>::queries( const std::string &opt_qs_name ) {
@@ -442,7 +447,7 @@ references<pvec_t,seq_tag>::references(const char* opt_tree_name, const char* op
{
//std::cerr << "papara_nt instantiated as: " << typeid(*this).name() << "\n";
- lout << "papara_nt instantiated as: " << ivy_mike::demangle(typeid(*this).name()) << "\n";
+ lout << "references container instantiated as: " << ivy_mike::demangle(typeid(*this).name()) << "\n";
@@ -1008,6 +1013,7 @@ void driver<pvec_t,seq_tag>::calc_scores(size_t n_threads, const my_references&
//
ivy_mike::timer t1;
ivy_mike::thread_group tg;
+ lout << "papara_core version " << papara::get_version_string() << std::endl;
lout << "start scoring, using " << n_threads << " threads" << std::endl;
typedef worker<seq_tag> worker_t;
View
2  papara.h
@@ -1073,7 +1073,7 @@ bool file_exists(const char *filename)
} // end anonymous namespace for inline util functions (move to impl file!)
-
+std::string get_version_string();
} // end of namespace papara
#endif
View
8 papara2_main.cpp
@@ -37,7 +37,7 @@ void print_banner( std::ostream &os ) {
os << "| __/ _` | __/ _` | // _` |\n";
os << "| | | (_| | | | (_| | |\\ \\ (_| |\n";
os << "\\_| \\__,_\\_| \\__,_\\_| \\_\\__,_|\n";
- os << " Version 2.3\n";
+ os << " papara_core version " << papara::get_version_string() << "\n";
}
@@ -219,8 +219,10 @@ void run_papara( const std::string &qs_name, const std::string &alignment_name,
int main( int argc, char *argv[] ) {
// aligned_buffer<int> xxx(1024);
-
-
+ char *xargv[9] = {"xxx", "-t", "C:/2012_robert_454/RAxML_bestTree.cora_Sanger_reference_alignment.tre", "-s", "C:/2012_robert_454/cora_Sanger_reference_alignment.phy",
+ "-q", "C:/2012_robert_454/cluster_52_72_cora_inversa_squamiformis_DIC_148_149.fas", "-j", "2" };
+ argv = (char**) xargv;
+ argc = 9;
namespace igo = ivy_mike::getopt;
View
14 stepwise_align.h
@@ -790,7 +790,7 @@ class pvec_aligner_vec {
size_t block_start_outer = a_start_idx;
//ptr_block_outer.s_iter = s_.base();
//ptr_block_outer.si_iter = si_.base();
-
+ //std::cerr << "sm_inc: " << &(*sm_inc_prof_.begin()) << std::endl;
ticks ticks1 = getticks();
@@ -841,14 +841,16 @@ class pvec_aligner_vec {
//aiter a_aux_end_this = ptr_block.a_aux_prof_iter + W * block_width;
- score_t * __restrict s_iter = s_.base();
- score_t * __restrict si_iter = si_.base();
+ score_t * s_iter = s_.base();
+ score_t * si_iter = si_.base();
// score_t * __restrict a_aux_prof_iter = &(*(a_aux_start + block_start * W));
// score_t * __restrict a_aux_prof_end = &(*(a_aux_start + block_end * W));
- score_t * __restrict sm_inc_iter = &(*(sm_inc_prof_.begin() + (*it_b) * av_size_all + block_start * W));
- score_t * __restrict sm_inc_end = &(*(sm_inc_prof_.begin() + (*it_b) * av_size_all + block_end * W));
+ score_t * sm_inc_iter = &(*(sm_inc_prof_.begin() + (*it_b) * av_size_all + block_start * W));
+ score_t * sm_inc_end = &(*(sm_inc_prof_.begin() + (*it_b) * av_size_all + block_end * W));
+
+
- _mm_prefetch( (const char *)sm_inc_iter, _MM_HINT_T0 );
+ // _mm_prefetch( (const char *)sm_inc_iter, _MM_HINT_T0 );
vec_t last_sdiag = vu::load( &(*block_sdiag_it));
Please sign in to comment.
Something went wrong with that request. Please try again.