diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-11 15:00:38 +0000 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-11 15:00:38 +0000 |
commit | 1262673ffcc013191dd7d9f08c9bc03f52b58ef6 (patch) | |
tree | 38249aa252abe01306ce86494579e59376331c8a /vespalib | |
parent | fe723e684f6bff17d698131806d3ae11688b9e17 (diff) |
Split out tensor and llvm part of eval to avoid bringing in llvm everywhere where it is not needed.
Diffstat (limited to 'vespalib')
48 files changed, 65 insertions, 51 deletions
diff --git a/vespalib/CMakeLists.txt b/vespalib/CMakeLists.txt index 2114afc2266..cfd8cc87d90 100644 --- a/vespalib/CMakeLists.txt +++ b/vespalib/CMakeLists.txt @@ -4,9 +4,6 @@ vespa_define_module( fastos vespalog - EXTERNAL_DEPENDS - LLVM-3.4 - APPS src/apps/eval_expr src/apps/make_fixture_macros @@ -129,6 +126,7 @@ vespa_define_module( src/vespa/vespalib/eval src/vespa/vespalib/eval/test src/vespa/vespalib/eval/value_cache + src/vespa/vespalib/eval/llvm src/vespa/vespalib/geo src/vespa/vespalib/io src/vespa/vespalib/net diff --git a/vespalib/src/apps/eval_expr/CMakeLists.txt b/vespalib/src/apps/eval_expr/CMakeLists.txt index 41f6b34c9d6..f576295717a 100644 --- a/vespalib/src/apps/eval_expr/CMakeLists.txt +++ b/vespalib/src/apps/eval_expr/CMakeLists.txt @@ -5,4 +5,5 @@ vespa_add_executable(vespalib_eval_expr_app INSTALL bin DEPENDS vespalib +# vespalib_vespalib_eval ) diff --git a/vespalib/src/tests/eval/compile_cache/CMakeLists.txt b/vespalib/src/tests/eval/compile_cache/CMakeLists.txt index 21edf07e638..5484ee9580b 100644 --- a/vespalib/src/tests/eval/compile_cache/CMakeLists.txt +++ b/vespalib/src/tests/eval/compile_cache/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_compile_cache_test_app TEST compile_cache_test.cpp DEPENDS vespalib + vespalib_vespalib_eval_llvm ) vespa_add_test(NAME vespalib_compile_cache_test_app COMMAND vespalib_compile_cache_test_app) diff --git a/vespalib/src/tests/eval/compile_cache/compile_cache_test.cpp b/vespalib/src/tests/eval/compile_cache/compile_cache_test.cpp index f6a125b3b25..1bbe9d2fa0b 100644 --- a/vespalib/src/tests/eval/compile_cache/compile_cache_test.cpp +++ b/vespalib/src/tests/eval/compile_cache/compile_cache_test.cpp @@ -1,6 +1,6 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/test_kit.h> -#include <vespa/vespalib/eval/compile_cache.h> +#include <vespa/vespalib/eval/llvm/compile_cache.h> #include <vespa/vespalib/eval/key_gen.h> #include <vespa/vespalib/eval/test/eval_spec.h> #include <set> diff --git a/vespalib/src/tests/eval/compiled_function/CMakeLists.txt b/vespalib/src/tests/eval/compiled_function/CMakeLists.txt index ca947ab6fd3..c362811c93e 100644 --- a/vespalib/src/tests/eval/compiled_function/CMakeLists.txt +++ b/vespalib/src/tests/eval/compiled_function/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_compiled_function_test_app TEST compiled_function_test.cpp DEPENDS vespalib + vespalib_vespalib_eval_llvm ) vespa_add_test(NAME vespalib_compiled_function_test_app COMMAND vespalib_compiled_function_test_app) diff --git a/vespalib/src/tests/eval/compiled_function/compiled_function_test.cpp b/vespalib/src/tests/eval/compiled_function/compiled_function_test.cpp index c9b33e8c54b..014682f802a 100644 --- a/vespalib/src/tests/eval/compiled_function/compiled_function_test.cpp +++ b/vespalib/src/tests/eval/compiled_function/compiled_function_test.cpp @@ -1,7 +1,7 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/vespalib/eval/function.h> -#include <vespa/vespalib/eval/compiled_function.h> +#include <vespa/vespalib/eval/llvm/compiled_function.h> #include <vespa/vespalib/eval/test/eval_spec.h> #include <vespa/vespalib/eval/basic_nodes.h> #include <vespa/vespalib/util/stringfmt.h> diff --git a/vespalib/src/tests/eval/function_speed/CMakeLists.txt b/vespalib/src/tests/eval/function_speed/CMakeLists.txt index 629d3dad483..310de28cf43 100644 --- a/vespalib/src/tests/eval/function_speed/CMakeLists.txt +++ b/vespalib/src/tests/eval/function_speed/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_function_speed_test_app TEST function_speed_test.cpp DEPENDS vespalib + vespalib_vespalib_eval_llvm ) vespa_add_test(NAME vespalib_function_speed_test_app NO_VALGRIND COMMAND vespalib_function_speed_test_app) diff --git a/vespalib/src/tests/eval/function_speed/function_speed_test.cpp b/vespalib/src/tests/eval/function_speed/function_speed_test.cpp index 784cfb157df..888d4c6cab8 100644 --- a/vespalib/src/tests/eval/function_speed/function_speed_test.cpp +++ b/vespalib/src/tests/eval/function_speed/function_speed_test.cpp @@ -1,7 +1,7 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/vespalib/eval/function.h> -#include <vespa/vespalib/eval/compiled_function.h> +#include <vespa/vespalib/eval/llvm/compiled_function.h> #include <vespa/vespalib/util/benchmark_timer.h> #include <vespa/vespalib/eval/interpreted_function.h> diff --git a/vespalib/src/tests/eval/gbdt/CMakeLists.txt b/vespalib/src/tests/eval/gbdt/CMakeLists.txt index c68614a5911..d6fc1c12e10 100644 --- a/vespalib/src/tests/eval/gbdt/CMakeLists.txt +++ b/vespalib/src/tests/eval/gbdt/CMakeLists.txt @@ -4,6 +4,7 @@ vespa_add_executable(vespalib_gbdt_test_app TEST gbdt_test.cpp DEPENDS vespalib + vespalib_vespalib_eval_llvm ) vespa_add_test(NAME vespalib_gbdt_test_app COMMAND vespalib_gbdt_test_app) vespa_add_executable(vespalib_gbdt_benchmark_app @@ -11,5 +12,6 @@ vespa_add_executable(vespalib_gbdt_benchmark_app gbdt_benchmark.cpp DEPENDS vespalib + vespalib_vespalib_eval_llvm ) vespa_add_test(NAME vespalib_gbdt_benchmark_app COMMAND vespalib_gbdt_benchmark_app BENCHMARK) diff --git a/vespalib/src/tests/eval/gbdt/gbdt_benchmark.cpp b/vespalib/src/tests/eval/gbdt/gbdt_benchmark.cpp index d1dacc39813..4c30135961e 100644 --- a/vespalib/src/tests/eval/gbdt/gbdt_benchmark.cpp +++ b/vespalib/src/tests/eval/gbdt/gbdt_benchmark.cpp @@ -1,10 +1,10 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/test_kit.h> -#include <vespa/vespalib/eval/gbdt.h> -#include <vespa/vespalib/eval/vm_forest.h> -#include <vespa/vespalib/eval/deinline_forest.h> +#include <vespa/vespalib/eval/llvm/gbdt.h> +#include <vespa/vespalib/eval/llvm/vm_forest.h> +#include <vespa/vespalib/eval/llvm/deinline_forest.h> +#include <vespa/vespalib/eval/llvm/compiled_function.h> #include <vespa/vespalib/eval/function.h> -#include <vespa/vespalib/eval/compiled_function.h> #include <vespa/vespalib/util/benchmark_timer.h> #include <vespa/vespalib/util/stringfmt.h> #include "model.cpp" diff --git a/vespalib/src/tests/eval/gbdt/gbdt_test.cpp b/vespalib/src/tests/eval/gbdt/gbdt_test.cpp index c5643abfd85..d8fb2dfc281 100644 --- a/vespalib/src/tests/eval/gbdt/gbdt_test.cpp +++ b/vespalib/src/tests/eval/gbdt/gbdt_test.cpp @@ -1,11 +1,11 @@ // Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/test_kit.h> -#include <vespa/vespalib/eval/gbdt.h> -#include <vespa/vespalib/eval/vm_forest.h> -#include <vespa/vespalib/eval/deinline_forest.h> +#include <vespa/vespalib/eval/llvm/gbdt.h> +#include <vespa/vespalib/eval/llvm/vm_forest.h> +#include <vespa/vespalib/eval/llvm/deinline_forest.h> #include <vespa/vespalib/eval/function.h> +#include <vespa/vespalib/eval/llvm/compiled_function.h> #include <vespa/vespalib/eval/interpreted_function.h> -#include <vespa/vespalib/eval/compiled_function.h> #include <vespa/vespalib/util/stringfmt.h> #include "model.cpp" diff --git a/vespalib/src/tests/eval/tensor/CMakeLists.txt b/vespalib/src/tests/eval/tensor/CMakeLists.txt index 5a84d73f3a3..07d961385ee 100644 --- a/vespalib/src/tests/eval/tensor/CMakeLists.txt +++ b/vespalib/src/tests/eval/tensor/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_eval_tensor_test_app TEST eval_tensor_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_eval_tensor_test_app COMMAND vespalib_eval_tensor_test_app) diff --git a/vespalib/src/tests/tensor/compact_tensor_builder/CMakeLists.txt b/vespalib/src/tests/tensor/compact_tensor_builder/CMakeLists.txt index b19fdf2f296..c9cd5c0387d 100644 --- a/vespalib/src/tests/tensor/compact_tensor_builder/CMakeLists.txt +++ b/vespalib/src/tests/tensor/compact_tensor_builder/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_compact_tensor_builder_test_app TEST compact_tensor_builder_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_compact_tensor_builder_test_app COMMAND vespalib_compact_tensor_builder_test_app) diff --git a/vespalib/src/tests/tensor/compact_tensor_v2_builder/CMakeLists.txt b/vespalib/src/tests/tensor/compact_tensor_v2_builder/CMakeLists.txt index 978e2f9142a..2bddcd3f021 100644 --- a/vespalib/src/tests/tensor/compact_tensor_v2_builder/CMakeLists.txt +++ b/vespalib/src/tests/tensor/compact_tensor_v2_builder/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_compact_tensor_v2_builder_test_app TEST compact_tensor_v2_builder_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_compact_tensor_v2_builder_test_app COMMAND vespalib_compact_tensor_v2_builder_test_app) diff --git a/vespalib/src/tests/tensor/dense_tensor_builder/CMakeLists.txt b/vespalib/src/tests/tensor/dense_tensor_builder/CMakeLists.txt index ffccbf52ec6..9028138ab87 100644 --- a/vespalib/src/tests/tensor/dense_tensor_builder/CMakeLists.txt +++ b/vespalib/src/tests/tensor/dense_tensor_builder/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_dense_tensor_builder_test_app TEST dense_tensor_builder_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_dense_tensor_builder_test_app COMMAND vespalib_dense_tensor_builder_test_app) diff --git a/vespalib/src/tests/tensor/dense_tensor_operations/CMakeLists.txt b/vespalib/src/tests/tensor/dense_tensor_operations/CMakeLists.txt index 2b23b2d5120..4805b8dcf22 100644 --- a/vespalib/src/tests/tensor/dense_tensor_operations/CMakeLists.txt +++ b/vespalib/src/tests/tensor/dense_tensor_operations/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_dense_tensor_operations_test_app TEST dense_tensor_operations_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_dense_tensor_operations_test_app COMMAND vespalib_dense_tensor_operations_test_app) diff --git a/vespalib/src/tests/tensor/join_tensor_addresses/CMakeLists.txt b/vespalib/src/tests/tensor/join_tensor_addresses/CMakeLists.txt index 9b59c1de09a..6923cbc1133 100644 --- a/vespalib/src/tests/tensor/join_tensor_addresses/CMakeLists.txt +++ b/vespalib/src/tests/tensor/join_tensor_addresses/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_join_tensor_addresses_test_app TEST join_tensor_addresses_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_join_tensor_addresses_test_app COMMAND vespalib_join_tensor_addresses_test_app) diff --git a/vespalib/src/tests/tensor/simple_tensor_builder/CMakeLists.txt b/vespalib/src/tests/tensor/simple_tensor_builder/CMakeLists.txt index 986492a8d37..cd67231d418 100644 --- a/vespalib/src/tests/tensor/simple_tensor_builder/CMakeLists.txt +++ b/vespalib/src/tests/tensor/simple_tensor_builder/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_simple_tensor_builder_test_app TEST simple_tensor_builder_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_simple_tensor_builder_test_app COMMAND vespalib_simple_tensor_builder_test_app) diff --git a/vespalib/src/tests/tensor/tensor/CMakeLists.txt b/vespalib/src/tests/tensor/tensor/CMakeLists.txt index b6d2ae2f5ee..bf902d3a71d 100644 --- a/vespalib/src/tests/tensor/tensor/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_test_app TEST tensor_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_test_app COMMAND vespalib_tensor_test_app) diff --git a/vespalib/src/tests/tensor/tensor_address/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_address/CMakeLists.txt index 7ea369549da..43c45f913a5 100644 --- a/vespalib/src/tests/tensor/tensor_address/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_address/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_address_test_app TEST tensor_address_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_address_test_app COMMAND vespalib_tensor_address_test_app) diff --git a/vespalib/src/tests/tensor/tensor_address_element_iterator/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_address_element_iterator/CMakeLists.txt index 59a07942600..dad69af7ba3 100644 --- a/vespalib/src/tests/tensor/tensor_address_element_iterator/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_address_element_iterator/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_address_element_iterator_test_app TEST tensor_address_element_iterator_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_address_element_iterator_test_app COMMAND vespalib_tensor_address_element_iterator_test_app) diff --git a/vespalib/src/tests/tensor/tensor_conformance/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_conformance/CMakeLists.txt index 21a0469de64..0aaddb481cc 100644 --- a/vespalib/src/tests/tensor/tensor_conformance/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_conformance/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_tensor_conformance_test_app TEST tensor_conformance_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_tensor_conformance_test_app COMMAND vespalib_tensor_tensor_conformance_test_app) diff --git a/vespalib/src/tests/tensor/tensor_function/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_function/CMakeLists.txt index f849258d900..cca15f932c9 100644 --- a/vespalib/src/tests/tensor/tensor_function/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_function/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_function_test_app TEST tensor_function_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_function_test_app COMMAND vespalib_tensor_function_test_app) diff --git a/vespalib/src/tests/tensor/tensor_mapper/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_mapper/CMakeLists.txt index 91e0a185a3a..fb18883f7ef 100644 --- a/vespalib/src/tests/tensor/tensor_mapper/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_mapper/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_mapper_test_app TEST tensor_mapper_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_mapper_test_app COMMAND vespalib_tensor_mapper_test_app) diff --git a/vespalib/src/tests/tensor/tensor_operations/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_operations/CMakeLists.txt index 7bf856d388e..9b18e5384e6 100644 --- a/vespalib/src/tests/tensor/tensor_operations/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_operations/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_operations_test_app TEST tensor_operations_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_operations_test_app COMMAND vespalib_tensor_operations_test_app) diff --git a/vespalib/src/tests/tensor/tensor_performance/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_performance/CMakeLists.txt index 8dd2bc72d61..a2f041db265 100644 --- a/vespalib/src/tests/tensor/tensor_performance/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_performance/CMakeLists.txt @@ -4,6 +4,7 @@ vespa_add_executable(vespalib_tensor_performance_test_app TEST tensor_performance_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test( NAME vespalib_tensor_performance_test_app diff --git a/vespalib/src/tests/tensor/tensor_serialization/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_serialization/CMakeLists.txt index e0e64b12e7f..2fdf47d4738 100644 --- a/vespalib/src/tests/tensor/tensor_serialization/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_serialization/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_serialization_test_app TEST tensor_serialization_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_serialization_test_app COMMAND vespalib_tensor_serialization_test_app) diff --git a/vespalib/src/tests/tensor/tensor_slime_serialization/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_slime_serialization/CMakeLists.txt index e002450f280..a0323928fd3 100644 --- a/vespalib/src/tests/tensor/tensor_slime_serialization/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_slime_serialization/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_slime_serialization_test_app TEST tensor_slime_serialization_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_slime_serialization_test_app COMMAND vespalib_tensor_slime_serialization_test_app) diff --git a/vespalib/src/tests/tensor/tensor_type/CMakeLists.txt b/vespalib/src/tests/tensor/tensor_type/CMakeLists.txt index feaa7a20c3c..e09801f3c79 100644 --- a/vespalib/src/tests/tensor/tensor_type/CMakeLists.txt +++ b/vespalib/src/tests/tensor/tensor_type/CMakeLists.txt @@ -4,5 +4,6 @@ vespa_add_executable(vespalib_tensor_type_test_app TEST tensor_type_test.cpp DEPENDS vespalib + vespalib_vespalib_tensor ) vespa_add_test(NAME vespalib_tensor_type_test_app COMMAND vespalib_tensor_type_test_app) diff --git a/vespalib/src/vespa/vespalib/eval/CMakeLists.txt b/vespalib/src/vespa/vespalib/eval/CMakeLists.txt index 3a94cff26c7..a3b4c39fbaa 100644 --- a/vespalib/src/vespa/vespalib/eval/CMakeLists.txt +++ b/vespalib/src/vespa/vespalib/eval/CMakeLists.txt @@ -3,15 +3,10 @@ vespa_add_library(vespalib_vespalib_eval OBJECT SOURCES basic_nodes.cpp call_nodes.cpp - compile_cache.cpp - compiled_function.cpp - deinline_forest.cpp delete_node.cpp function.cpp - gbdt.cpp interpreted_function.cpp key_gen.cpp - llvm_wrapper.cpp node_types.cpp operation.cpp operator_nodes.cpp @@ -24,6 +19,4 @@ vespa_add_library(vespalib_vespalib_eval OBJECT value.cpp value_type.cpp value_type_spec.cpp - vm_forest.cpp - DEPENDS ) diff --git a/vespalib/src/vespa/vespalib/eval/delete_node.cpp b/vespalib/src/vespa/vespalib/eval/delete_node.cpp index c36c5864876..61204c890b2 100644 --- a/vespalib/src/vespa/vespalib/eval/delete_node.cpp +++ b/vespalib/src/vespa/vespalib/eval/delete_node.cpp @@ -4,7 +4,6 @@ #include "key_gen.h" #include "node_visitor.h" #include "node_traverser.h" -#include "compiled_function.h" namespace vespalib { namespace eval { diff --git a/vespalib/src/vespa/vespalib/eval/function.h b/vespalib/src/vespa/vespalib/eval/function.h index ac097afb22e..6896be6b46b 100644 --- a/vespalib/src/vespa/vespalib/eval/function.h +++ b/vespalib/src/vespa/vespalib/eval/function.h @@ -14,6 +14,8 @@ namespace vespalib { namespace eval { +enum class PassParams { SEPARATE, ARRAY }; + /** * Interface used to perform custom symbol extraction. This is * typically used by the ranking framework to extend what will be diff --git a/vespalib/src/vespa/vespalib/eval/key_gen.cpp b/vespalib/src/vespa/vespalib/eval/key_gen.cpp index 13795486142..d259eed791a 100644 --- a/vespalib/src/vespa/vespalib/eval/key_gen.cpp +++ b/vespalib/src/vespa/vespalib/eval/key_gen.cpp @@ -4,7 +4,7 @@ #include "key_gen.h" #include "node_visitor.h" #include "node_traverser.h" -#include "compiled_function.h" +#include "function.h" namespace vespalib { namespace eval { diff --git a/vespalib/src/vespa/vespalib/eval/llvm/CMakeLists.txt b/vespalib/src/vespa/vespalib/eval/llvm/CMakeLists.txt new file mode 100644 index 00000000000..73f2ffecf0b --- /dev/null +++ b/vespalib/src/vespa/vespalib/eval/llvm/CMakeLists.txt @@ -0,0 +1,12 @@ +# Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +vespa_add_library(vespalib_vespalib_eval_llvm + SOURCES + compile_cache.cpp + compiled_function.cpp + deinline_forest.cpp + gbdt.cpp + llvm_wrapper.cpp + vm_forest.cpp + DEPENDS + LLVM-3.4 +) diff --git a/vespalib/src/vespa/vespalib/eval/compile_cache.cpp b/vespalib/src/vespa/vespalib/eval/llvm/compile_cache.cpp index 2a104f87f84..1f7731da403 100644 --- a/vespalib/src/vespa/vespalib/eval/compile_cache.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/compile_cache.cpp @@ -2,7 +2,7 @@ #include <vespa/fastos/fastos.h> #include "compile_cache.h" -#include "key_gen.h" +#include <vespa/vespalib/eval/key_gen.h> #include <thread> namespace vespalib { diff --git a/vespalib/src/vespa/vespalib/eval/compile_cache.h b/vespalib/src/vespa/vespalib/eval/llvm/compile_cache.h index f137b37ba85..f137b37ba85 100644 --- a/vespalib/src/vespa/vespalib/eval/compile_cache.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/compile_cache.h diff --git a/vespalib/src/vespa/vespalib/eval/compiled_function.cpp b/vespalib/src/vespa/vespalib/eval/llvm/compiled_function.cpp index 957df7503c3..957df7503c3 100644 --- a/vespalib/src/vespa/vespalib/eval/compiled_function.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/compiled_function.cpp diff --git a/vespalib/src/vespa/vespalib/eval/compiled_function.h b/vespalib/src/vespa/vespalib/eval/llvm/compiled_function.h index 0c9e9a4a8fc..412c4c673cb 100644 --- a/vespalib/src/vespa/vespalib/eval/compiled_function.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/compiled_function.h @@ -2,15 +2,13 @@ #pragma once -#include "function.h" +#include <vespa/vespalib/eval/function.h> #include "gbdt.h" #include "llvm_wrapper.h" namespace vespalib { namespace eval { -enum class PassParams { SEPARATE, ARRAY }; - /** * A Function that has been compiled to machine code using LLVM. Note * that tensors are currently not supported for compiled functions. diff --git a/vespalib/src/vespa/vespalib/eval/deinline_forest.cpp b/vespalib/src/vespa/vespalib/eval/llvm/deinline_forest.cpp index ffe0f1c2eaf..ffe0f1c2eaf 100644 --- a/vespalib/src/vespa/vespalib/eval/deinline_forest.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/deinline_forest.cpp diff --git a/vespalib/src/vespa/vespalib/eval/deinline_forest.h b/vespalib/src/vespa/vespalib/eval/llvm/deinline_forest.h index 883720d47d0..883720d47d0 100644 --- a/vespalib/src/vespa/vespalib/eval/deinline_forest.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/deinline_forest.h diff --git a/vespalib/src/vespa/vespalib/eval/gbdt.cpp b/vespalib/src/vespa/vespalib/eval/llvm/gbdt.cpp index 66ae096bac6..f3851db5a92 100644 --- a/vespalib/src/vespa/vespalib/eval/gbdt.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/gbdt.cpp @@ -2,9 +2,9 @@ #include <vespa/fastos/fastos.h> #include "gbdt.h" -#include "basic_nodes.h" -#include "call_nodes.h" -#include "operator_nodes.h" +#include <vespa/vespalib/eval/basic_nodes.h> +#include <vespa/vespalib/eval/call_nodes.h> +#include <vespa/vespalib/eval/operator_nodes.h> #include "vm_forest.h" #include "deinline_forest.h" diff --git a/vespalib/src/vespa/vespalib/eval/gbdt.h b/vespalib/src/vespa/vespalib/eval/llvm/gbdt.h index c7ec59b603c..c7ec59b603c 100644 --- a/vespalib/src/vespa/vespalib/eval/gbdt.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/gbdt.h diff --git a/vespalib/src/vespa/vespalib/eval/llvm_wrapper.cpp b/vespalib/src/vespa/vespalib/eval/llvm/llvm_wrapper.cpp index e21511de4f9..bafade984ff 100644 --- a/vespalib/src/vespa/vespalib/eval/llvm_wrapper.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/llvm_wrapper.cpp @@ -3,8 +3,8 @@ #include <vespa/fastos/fastos.h> #include <cmath> #include "llvm_wrapper.h" -#include "node_visitor.h" -#include "node_traverser.h" +#include <vespa/vespalib/eval/node_visitor.h> +#include <vespa/vespalib/eval/node_traverser.h> #include <llvm/Analysis/Verifier.h> #include <llvm/IR/IRBuilder.h> #include <llvm/IR/Intrinsics.h> @@ -15,7 +15,7 @@ #include <llvm/LinkAllPasses.h> #include <llvm/Transforms/IPO/PassManagerBuilder.h> #include "gbdt.h" -#include "check_type.h" +#include <vespa/vespalib/eval/check_type.h> #include <vespa/vespalib/stllike/hash_set.h> #include <vespa/vespalib/util/approx.h> diff --git a/vespalib/src/vespa/vespalib/eval/llvm_wrapper.h b/vespalib/src/vespa/vespalib/eval/llvm/llvm_wrapper.h index dc9c4d8b71b..34c74909765 100644 --- a/vespalib/src/vespa/vespalib/eval/llvm_wrapper.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/llvm_wrapper.h @@ -2,7 +2,7 @@ #pragma once -#include "function.h" +#include <vespa/vespalib/eval/function.h> #include "gbdt.h" #include <llvm/IR/LLVMContext.h> diff --git a/vespalib/src/vespa/vespalib/eval/vm_forest.cpp b/vespalib/src/vespa/vespalib/eval/llvm/vm_forest.cpp index d9e9106065b..5c7164bab73 100644 --- a/vespalib/src/vespa/vespalib/eval/vm_forest.cpp +++ b/vespalib/src/vespa/vespalib/eval/llvm/vm_forest.cpp @@ -3,9 +3,9 @@ #include <vespa/fastos/fastos.h> #include "gbdt.h" #include "vm_forest.h" -#include "basic_nodes.h" -#include "call_nodes.h" -#include "operator_nodes.h" +#include <vespa/vespalib/eval/basic_nodes.h> +#include <vespa/vespalib/eval/call_nodes.h> +#include <vespa/vespalib/eval/operator_nodes.h> namespace vespalib { namespace eval { diff --git a/vespalib/src/vespa/vespalib/eval/vm_forest.h b/vespalib/src/vespa/vespalib/eval/llvm/vm_forest.h index 48e2bdf9cf6..48e2bdf9cf6 100644 --- a/vespalib/src/vespa/vespalib/eval/vm_forest.h +++ b/vespalib/src/vespa/vespalib/eval/llvm/vm_forest.h diff --git a/vespalib/src/vespa/vespalib/tensor/tensor_type.cpp b/vespalib/src/vespa/vespalib/tensor/tensor_type.cpp index 2aacd579aa2..608902325ec 100644 --- a/vespalib/src/vespa/vespalib/tensor/tensor_type.cpp +++ b/vespalib/src/vespa/vespalib/tensor/tensor_type.cpp @@ -127,18 +127,6 @@ TensorType::as_value_type() const } TensorType -TensorType::invalid() -{ - return TensorType(Type::INVALID); -} - -TensorType -TensorType::number() -{ - return TensorType(Type::NUMBER); -} - -TensorType TensorType::sparse(const std::vector<vespalib::string> &dimensions_in) { std::vector<Dimension> dimensions; diff --git a/vespalib/src/vespa/vespalib/tensor/tensor_type.h b/vespalib/src/vespa/vespalib/tensor/tensor_type.h index 1ff5fea758b..1cc0b70beb8 100644 --- a/vespalib/src/vespa/vespalib/tensor/tensor_type.h +++ b/vespalib/src/vespa/vespalib/tensor/tensor_type.h @@ -73,8 +73,8 @@ public: eval::ValueType as_value_type() const; - static TensorType invalid(); - static TensorType number(); + static TensorType invalid() { return TensorType(Type::INVALID); } + static TensorType number() { return TensorType(Type::NUMBER); } static TensorType sparse(const std::vector<vespalib::string> &dimensions_in); static TensorType dense(std::vector<Dimension> dimensions_in); static TensorType fromSpec(const vespalib::string &str); |