diff options
author | 2017-07-19 09:28:38 -0700 | |
---|---|---|
committer | 2017-07-24 16:07:10 -0700 | |
commit | 8cf9cb386cd9286d67e879f1ee501ec00d72a4e1 (patch) | |
tree | 88e86e214b425e444760fe4e0ffeee677e1558a2 /compiler | |
parent | 914b7b6a6c9f399b26b41e9160e9871ef749e0db (diff) |
ART: Include cleanup
Let clang-format reorder the header includes.
Derived with:
* .clang-format:
BasedOnStyle: Google
IncludeIsMainRegex: '(_test|-inl)?$'
* Steps:
find . -name '*.cc' -o -name '*.h' | xargs sed -i.bak -e 's/^#include/ #include/' ; git commit -a -m 'ART: Include cleanup'
git-clang-format -style=file HEAD^
manual inspection
git commit -a --amend
Test: mmma art
Change-Id: Ia963a8ce3ce5f96b5e78acd587e26908c7a70d02
Diffstat (limited to 'compiler')
104 files changed, 190 insertions, 150 deletions
diff --git a/compiler/cfi_test.h b/compiler/cfi_test.h index c754e5588c..5347e7fef3 100644 --- a/compiler/cfi_test.h +++ b/compiler/cfi_test.h @@ -17,9 +17,9 @@ #ifndef ART_COMPILER_CFI_TEST_H_ #define ART_COMPILER_CFI_TEST_H_ -#include <vector> #include <memory> #include <sstream> +#include <vector> #include "arch/instruction_set.h" #include "base/enums.h" diff --git a/compiler/common_compiler_test.cc b/compiler/common_compiler_test.cc index 07bfe31e14..a9a718f43c 100644 --- a/compiler/common_compiler_test.cc +++ b/compiler/common_compiler_test.cc @@ -28,8 +28,8 @@ #include "driver/compiler_driver.h" #include "driver/compiler_options.h" #include "interpreter/interpreter.h" -#include "mirror/class_loader.h" #include "mirror/class-inl.h" +#include "mirror/class_loader.h" #include "mirror/dex_cache.h" #include "mirror/object-inl.h" #include "oat_quick_method_header.h" diff --git a/compiler/compiled_method.h b/compiler/compiled_method.h index 761e9e19a8..97127f58ed 100644 --- a/compiler/compiled_method.h +++ b/compiler/compiled_method.h @@ -17,8 +17,8 @@ #ifndef ART_COMPILER_COMPILED_METHOD_H_ #define ART_COMPILER_COMPILED_METHOD_H_ -#include <memory> #include <iosfwd> +#include <memory> #include <string> #include <vector> diff --git a/compiler/compiler.h b/compiler/compiler.h index ba89cb1aed..6c542c841a 100644 --- a/compiler/compiler.h +++ b/compiler/compiler.h @@ -17,8 +17,8 @@ #ifndef ART_COMPILER_COMPILER_H_ #define ART_COMPILER_COMPILER_H_ -#include "dex_file.h" #include "base/mutex.h" +#include "dex_file.h" #include "os.h" namespace art { diff --git a/compiler/debug/dwarf/dwarf_test.h b/compiler/debug/dwarf/dwarf_test.h index e2f0a65ab7..e1f538d9a7 100644 --- a/compiler/debug/dwarf/dwarf_test.h +++ b/compiler/debug/dwarf/dwarf_test.h @@ -17,13 +17,14 @@ #ifndef ART_COMPILER_DEBUG_DWARF_DWARF_TEST_H_ #define ART_COMPILER_DEBUG_DWARF_DWARF_TEST_H_ -#include <cstring> #include <dirent.h> +#include <stdio.h> +#include <sys/types.h> + +#include <cstring> #include <memory> #include <set> -#include <stdio.h> #include <string> -#include <sys/types.h> #include "base/unix_file/fd_file.h" #include "common_runtime_test.h" diff --git a/compiler/dex/dex_to_dex_decompiler_test.cc b/compiler/dex/dex_to_dex_decompiler_test.cc index 88426a3b5f..7b56f3ec1a 100644 --- a/compiler/dex/dex_to_dex_decompiler_test.cc +++ b/compiler/dex/dex_to_dex_decompiler_test.cc @@ -19,16 +19,16 @@ #include "class_linker.h" #include "compiler/common_compiler_test.h" #include "compiler/compiled_method.h" -#include "compiler/driver/compiler_options.h" #include "compiler/driver/compiler_driver.h" +#include "compiler/driver/compiler_options.h" #include "compiler_callbacks.h" #include "dex_file.h" #include "handle_scope-inl.h" -#include "verifier/method_verifier-inl.h" #include "mirror/class_loader.h" #include "runtime.h" -#include "thread.h" #include "scoped_thread_state_change-inl.h" +#include "thread.h" +#include "verifier/method_verifier-inl.h" namespace art { diff --git a/compiler/dex/inline_method_analyser.cc b/compiler/dex/inline_method_analyser.cc index e5ff7fcace..54ddc2188b 100644 --- a/compiler/dex/inline_method_analyser.cc +++ b/compiler/dex/inline_method_analyser.cc @@ -21,8 +21,8 @@ #include "base/enums.h" #include "class_linker-inl.h" #include "dex_file-inl.h" -#include "dex_instruction.h" #include "dex_instruction-inl.h" +#include "dex_instruction.h" #include "dex_instruction_utils.h" #include "mirror/class-inl.h" #include "mirror/dex_cache-inl.h" diff --git a/compiler/dex/quick_compiler_callbacks.cc b/compiler/dex/quick_compiler_callbacks.cc index b1006b2f0b..872f7ea15d 100644 --- a/compiler/dex/quick_compiler_callbacks.cc +++ b/compiler/dex/quick_compiler_callbacks.cc @@ -16,8 +16,8 @@ #include "quick_compiler_callbacks.h" -#include "verifier/method_verifier-inl.h" #include "verification_results.h" +#include "verifier/method_verifier-inl.h" namespace art { diff --git a/compiler/dex/verification_results.cc b/compiler/dex/verification_results.cc index beb3439e62..e657e3bc86 100644 --- a/compiler/dex/verification_results.cc +++ b/compiler/dex/verification_results.cc @@ -22,8 +22,8 @@ #include "driver/compiler_driver.h" #include "driver/compiler_options.h" #include "runtime.h" -#include "thread.h" #include "thread-current-inl.h" +#include "thread.h" #include "utils/atomic_dex_ref_map-inl.h" #include "verified_method.h" #include "verifier/method_verifier-inl.h" diff --git a/compiler/driver/compiled_method_storage_test.cc b/compiler/driver/compiled_method_storage_test.cc index bbd28b2576..2ec2af587e 100644 --- a/compiler/driver/compiled_method_storage_test.cc +++ b/compiler/driver/compiled_method_storage_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "compiled_method_storage.h" + #include <gtest/gtest.h> -#include "compiled_method_storage.h" #include "compiled_method.h" #include "compiler_driver.h" #include "compiler_options.h" diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc index dd58bc7d13..da375b64b9 100644 --- a/compiler/driver/compiler_driver.cc +++ b/compiler/driver/compiler_driver.cc @@ -16,9 +16,9 @@ #include "compiler_driver.h" +#include <unistd.h> #include <unordered_set> #include <vector> -#include <unistd.h> #ifndef __APPLE__ #include <malloc.h> // For mallinfo @@ -409,7 +409,7 @@ void CompilerDriver::CompileAll(jobject class_loader, ClassName, MethodName, Signature) \ SetupIntrinsic(soa.Self(), Intrinsics::k##Name, InvokeType, ClassName, MethodName, Signature); #include "intrinsics_list.h" -INTRINSICS_LIST(SETUP_INTRINSICS) + INTRINSICS_LIST(SETUP_INTRINSICS) #undef INTRINSICS_LIST #undef SETUP_INTRINSICS } diff --git a/compiler/driver/compiler_driver.h b/compiler/driver/compiler_driver.h index 93234cbdc4..ecaed83e57 100644 --- a/compiler/driver/compiler_driver.h +++ b/compiler/driver/compiler_driver.h @@ -32,8 +32,8 @@ #include "dex_file.h" #include "dex_file_types.h" #include "driver/compiled_method_storage.h" -#include "jit/profile_compilation_info.h" #include "invoke_type.h" +#include "jit/profile_compilation_info.h" #include "method_reference.h" #include "mirror/class.h" // For mirror::Class::Status. #include "os.h" diff --git a/compiler/driver/compiler_driver_test.cc b/compiler/driver/compiler_driver_test.cc index 5d1d972e52..10bfd972f0 100644 --- a/compiler/driver/compiler_driver_test.cc +++ b/compiler/driver/compiler_driver_test.cc @@ -26,13 +26,13 @@ #include "dex_file.h" #include "dex_file_types.h" #include "gc/heap.h" +#include "handle_scope-inl.h" +#include "jit/profile_compilation_info.h" #include "mirror/class-inl.h" #include "mirror/class_loader.h" #include "mirror/dex_cache-inl.h" -#include "mirror/object_array-inl.h" #include "mirror/object-inl.h" -#include "handle_scope-inl.h" -#include "jit/profile_compilation_info.h" +#include "mirror/object_array-inl.h" #include "scoped_thread_state_change-inl.h" namespace art { diff --git a/compiler/elf_writer_test.cc b/compiler/elf_writer_test.cc index fa2d78d2e8..984e9ee4e9 100644 --- a/compiler/elf_writer_test.cc +++ b/compiler/elf_writer_test.cc @@ -18,9 +18,9 @@ #include "base/unix_file/fd_file.h" #include "common_compiler_test.h" +#include "elf_builder.h" #include "elf_file.h" #include "elf_file_impl.h" -#include "elf_builder.h" #include "elf_writer_quick.h" #include "oat.h" #include "utils.h" diff --git a/compiler/exception_test.cc b/compiler/exception_test.cc index 0b3ca69846..f759aa5ef8 100644 --- a/compiler/exception_test.cc +++ b/compiler/exception_test.cc @@ -21,19 +21,19 @@ #include "base/enums.h" #include "class_linker.h" #include "common_runtime_test.h" -#include "dex_file.h" #include "dex_file-inl.h" +#include "dex_file.h" #include "gtest/gtest.h" +#include "handle_scope-inl.h" #include "leb128.h" #include "mirror/class-inl.h" -#include "mirror/object_array-inl.h" #include "mirror/object-inl.h" +#include "mirror/object_array-inl.h" #include "mirror/stack_trace_element.h" #include "oat_quick_method_header.h" #include "optimizing/stack_map_stream.h" #include "runtime-inl.h" #include "scoped_thread_state_change-inl.h" -#include "handle_scope-inl.h" #include "thread.h" namespace art { diff --git a/compiler/image_test.h b/compiler/image_test.h index 6c3a89b7a2..57d0987982 100644 --- a/compiler/image_test.h +++ b/compiler/image_test.h @@ -28,8 +28,8 @@ #include "art_method-inl.h" #include "base/unix_file/fd_file.h" #include "class_linker-inl.h" -#include "compiler_callbacks.h" #include "common_compiler_test.h" +#include "compiler_callbacks.h" #include "debug/method_debug_info.h" #include "dex/quick_compiler_callbacks.h" #include "driver/compiler_options.h" diff --git a/compiler/image_writer.cc b/compiler/image_writer.cc index 51730cf23d..318009c606 100644 --- a/compiler/image_writer.cc +++ b/compiler/image_writer.cc @@ -16,9 +16,9 @@ #include "image_writer.h" -#include <sys/stat.h> #include <lz4.h> #include <lz4hc.h> +#include <sys/stat.h> #include <memory> #include <numeric> @@ -43,8 +43,8 @@ #include "gc/accounting/heap_bitmap.h" #include "gc/accounting/space_bitmap-inl.h" #include "gc/collector/concurrent_copying.h" -#include "gc/heap.h" #include "gc/heap-visit-objects-inl.h" +#include "gc/heap.h" #include "gc/space/large_object_space.h" #include "gc/space/space-inl.h" #include "gc/verification.h" @@ -59,8 +59,8 @@ #include "mirror/class-inl.h" #include "mirror/class_ext.h" #include "mirror/class_loader.h" -#include "mirror/dex_cache.h" #include "mirror/dex_cache-inl.h" +#include "mirror/dex_cache.h" #include "mirror/executable.h" #include "mirror/method.h" #include "mirror/object-inl.h" diff --git a/compiler/image_writer.h b/compiler/image_writer.h index ee6fc1dff6..34bbbad75d 100644 --- a/compiler/image_writer.h +++ b/compiler/image_writer.h @@ -22,10 +22,10 @@ #include <cstddef> #include <memory> +#include <ostream> #include <set> #include <stack> #include <string> -#include <ostream> #include "art_method.h" #include "base/bit_utils.h" @@ -40,8 +40,8 @@ #include "lock_word.h" #include "mem_map.h" #include "mirror/dex_cache.h" -#include "obj_ptr.h" #include "oat_file.h" +#include "obj_ptr.h" #include "os.h" #include "safe_map.h" #include "utils.h" diff --git a/compiler/jit/jit_compiler.h b/compiler/jit/jit_compiler.h index f0f24d345e..1e1838efd5 100644 --- a/compiler/jit/jit_compiler.h +++ b/compiler/jit/jit_compiler.h @@ -19,9 +19,9 @@ #include "base/mutex.h" #include "compiled_method.h" -#include "jit_logger.h" #include "driver/compiler_driver.h" #include "driver/compiler_options.h" +#include "jit_logger.h" namespace art { diff --git a/compiler/jni/quick/arm/calling_convention_arm.cc b/compiler/jni/quick/arm/calling_convention_arm.cc index 3f29ae5dcb..7e1ad9fd7b 100644 --- a/compiler/jni/quick/arm/calling_convention_arm.cc +++ b/compiler/jni/quick/arm/calling_convention_arm.cc @@ -14,8 +14,9 @@ * limitations under the License. */ -#include "base/logging.h" #include "calling_convention_arm.h" + +#include "base/logging.h" #include "handle_scope-inl.h" #include "utils/arm/managed_register_arm.h" diff --git a/compiler/jni/quick/arm64/calling_convention_arm64.cc b/compiler/jni/quick/arm64/calling_convention_arm64.cc index e086455620..292ce1039e 100644 --- a/compiler/jni/quick/arm64/calling_convention_arm64.cc +++ b/compiler/jni/quick/arm64/calling_convention_arm64.cc @@ -14,8 +14,9 @@ * limitations under the License. */ -#include "base/logging.h" #include "calling_convention_arm64.h" + +#include "base/logging.h" #include "handle_scope-inl.h" #include "utils/arm64/managed_register_arm64.h" diff --git a/compiler/jni/quick/jni_compiler.cc b/compiler/jni/quick/jni_compiler.cc index 68ec7bd860..b65b93f05f 100644 --- a/compiler/jni/quick/jni_compiler.cc +++ b/compiler/jni/quick/jni_compiler.cc @@ -17,36 +17,36 @@ #include "jni_compiler.h" #include <algorithm> +#include <fstream> #include <ios> #include <memory> #include <vector> -#include <fstream> #include "art_method.h" #include "base/arena_allocator.h" #include "base/enums.h" #include "base/logging.h" #include "base/macros.h" -#include "memory_region.h" #include "calling_convention.h" #include "class_linker.h" #include "compiled_method.h" +#include "debug/dwarf/debug_frame_opcode_writer.h" #include "dex_file-inl.h" #include "driver/compiler_driver.h" #include "driver/compiler_options.h" #include "entrypoints/quick/quick_entrypoints.h" #include "jni_env_ext.h" -#include "debug/dwarf/debug_frame_opcode_writer.h" +#include "memory_region.h" +#include "thread.h" +#include "utils.h" +#include "utils/arm/managed_register_arm.h" +#include "utils/arm64/managed_register_arm64.h" #include "utils/assembler.h" #include "utils/jni_macro_assembler.h" #include "utils/managed_register.h" -#include "utils/arm/managed_register_arm.h" -#include "utils/arm64/managed_register_arm64.h" #include "utils/mips/managed_register_mips.h" #include "utils/mips64/managed_register_mips64.h" #include "utils/x86/managed_register_x86.h" -#include "utils.h" -#include "thread.h" #define __ jni_asm-> diff --git a/compiler/linker/arm/relative_patcher_thumb2.cc b/compiler/linker/arm/relative_patcher_thumb2.cc index 18d6b9ad03..2ac2a1d2fc 100644 --- a/compiler/linker/arm/relative_patcher_thumb2.cc +++ b/compiler/linker/arm/relative_patcher_thumb2.cc @@ -22,8 +22,8 @@ #include "compiled_method.h" #include "entrypoints/quick/quick_entrypoints_enum.h" #include "lock_word.h" -#include "mirror/object.h" #include "mirror/array-inl.h" +#include "mirror/object.h" #include "read_barrier.h" #include "utils/arm/assembler_arm_vixl.h" diff --git a/compiler/linker/arm/relative_patcher_thumb2_test.cc b/compiler/linker/arm/relative_patcher_thumb2_test.cc index 52e27afcf5..fe76dfe39a 100644 --- a/compiler/linker/arm/relative_patcher_thumb2_test.cc +++ b/compiler/linker/arm/relative_patcher_thumb2_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "linker/arm/relative_patcher_thumb2.h" + #include "base/casts.h" #include "linker/relative_patcher_test.h" -#include "linker/arm/relative_patcher_thumb2.h" #include "lock_word.h" #include "mirror/array-inl.h" #include "mirror/object.h" diff --git a/compiler/linker/arm64/relative_patcher_arm64.cc b/compiler/linker/arm64/relative_patcher_arm64.cc index 38c732b8ba..db829f3233 100644 --- a/compiler/linker/arm64/relative_patcher_arm64.cc +++ b/compiler/linker/arm64/relative_patcher_arm64.cc @@ -25,8 +25,8 @@ #include "entrypoints/quick/quick_entrypoints_enum.h" #include "linker/output_stream.h" #include "lock_word.h" -#include "mirror/object.h" #include "mirror/array-inl.h" +#include "mirror/object.h" #include "oat.h" #include "oat_quick_method_header.h" #include "read_barrier.h" diff --git a/compiler/linker/arm64/relative_patcher_arm64_test.cc b/compiler/linker/arm64/relative_patcher_arm64_test.cc index 5d02d449fe..d6919e9417 100644 --- a/compiler/linker/arm64/relative_patcher_arm64_test.cc +++ b/compiler/linker/arm64/relative_patcher_arm64_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "linker/arm64/relative_patcher_arm64.h" + #include "base/casts.h" #include "linker/relative_patcher_test.h" -#include "linker/arm64/relative_patcher_arm64.h" #include "lock_word.h" #include "mirror/array-inl.h" #include "mirror/object.h" diff --git a/compiler/linker/mips/relative_patcher_mips.h b/compiler/linker/mips/relative_patcher_mips.h index 0b74bd33a4..d6eda34592 100644 --- a/compiler/linker/mips/relative_patcher_mips.h +++ b/compiler/linker/mips/relative_patcher_mips.h @@ -17,8 +17,8 @@ #ifndef ART_COMPILER_LINKER_MIPS_RELATIVE_PATCHER_MIPS_H_ #define ART_COMPILER_LINKER_MIPS_RELATIVE_PATCHER_MIPS_H_ -#include "linker/relative_patcher.h" #include "arch/mips/instruction_set_features_mips.h" +#include "linker/relative_patcher.h" namespace art { namespace linker { diff --git a/compiler/linker/mips/relative_patcher_mips32r6_test.cc b/compiler/linker/mips/relative_patcher_mips32r6_test.cc index d1a75e28a2..586e2aa8b2 100644 --- a/compiler/linker/mips/relative_patcher_mips32r6_test.cc +++ b/compiler/linker/mips/relative_patcher_mips32r6_test.cc @@ -14,8 +14,8 @@ * limitations under the License. */ -#include "linker/relative_patcher_test.h" #include "linker/mips/relative_patcher_mips.h" +#include "linker/relative_patcher_test.h" namespace art { namespace linker { diff --git a/compiler/linker/mips/relative_patcher_mips_test.cc b/compiler/linker/mips/relative_patcher_mips_test.cc index 2f7a0752a6..ebe5406512 100644 --- a/compiler/linker/mips/relative_patcher_mips_test.cc +++ b/compiler/linker/mips/relative_patcher_mips_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ -#include "linker/relative_patcher_test.h" #include "linker/mips/relative_patcher_mips.h" +#include "linker/relative_patcher_test.h" + namespace art { namespace linker { diff --git a/compiler/linker/mips64/relative_patcher_mips64_test.cc b/compiler/linker/mips64/relative_patcher_mips64_test.cc index a5f494d645..4edcae72f6 100644 --- a/compiler/linker/mips64/relative_patcher_mips64_test.cc +++ b/compiler/linker/mips64/relative_patcher_mips64_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ -#include "linker/relative_patcher_test.h" #include "linker/mips64/relative_patcher_mips64.h" +#include "linker/relative_patcher_test.h" + namespace art { namespace linker { diff --git a/compiler/linker/multi_oat_relative_patcher.cc b/compiler/linker/multi_oat_relative_patcher.cc index e9e242b658..4ae75d61c7 100644 --- a/compiler/linker/multi_oat_relative_patcher.cc +++ b/compiler/linker/multi_oat_relative_patcher.cc @@ -16,9 +16,9 @@ #include "multi_oat_relative_patcher.h" -#include "globals.h" #include "base/bit_utils.h" #include "base/logging.h" +#include "globals.h" namespace art { namespace linker { diff --git a/compiler/linker/multi_oat_relative_patcher_test.cc b/compiler/linker/multi_oat_relative_patcher_test.cc index 615b2b97be..e96790115a 100644 --- a/compiler/linker/multi_oat_relative_patcher_test.cc +++ b/compiler/linker/multi_oat_relative_patcher_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "multi_oat_relative_patcher.h" + #include "compiled_method.h" #include "gtest/gtest.h" -#include "multi_oat_relative_patcher.h" #include "vector_output_stream.h" namespace art { diff --git a/compiler/linker/output_stream_test.cc b/compiler/linker/output_stream_test.cc index 09fef29d48..87cb10000b 100644 --- a/compiler/linker/output_stream_test.cc +++ b/compiler/linker/output_stream_test.cc @@ -17,8 +17,8 @@ #include "file_output_stream.h" #include "vector_output_stream.h" -#include "base/unix_file/fd_file.h" #include "base/logging.h" +#include "base/unix_file/fd_file.h" #include "buffered_output_stream.h" #include "common_runtime_test.h" diff --git a/compiler/linker/vector_output_stream.h b/compiler/linker/vector_output_stream.h index 321014374e..a9b93e7a83 100644 --- a/compiler/linker/vector_output_stream.h +++ b/compiler/linker/vector_output_stream.h @@ -19,8 +19,8 @@ #include "output_stream.h" -#include <string> #include <string.h> +#include <string> #include <vector> namespace art { diff --git a/compiler/linker/x86/relative_patcher_x86_test.cc b/compiler/linker/x86/relative_patcher_x86_test.cc index 0bd9de8e15..4f74cee384 100644 --- a/compiler/linker/x86/relative_patcher_x86_test.cc +++ b/compiler/linker/x86/relative_patcher_x86_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ -#include "linker/relative_patcher_test.h" #include "linker/x86/relative_patcher_x86.h" +#include "linker/relative_patcher_test.h" + namespace art { namespace linker { diff --git a/compiler/linker/x86_64/relative_patcher_x86_64_test.cc b/compiler/linker/x86_64/relative_patcher_x86_64_test.cc index 6d6bb40fb4..ae17aa7a5f 100644 --- a/compiler/linker/x86_64/relative_patcher_x86_64_test.cc +++ b/compiler/linker/x86_64/relative_patcher_x86_64_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ -#include "linker/relative_patcher_test.h" #include "linker/x86_64/relative_patcher_x86_64.h" +#include "linker/relative_patcher_test.h" + namespace art { namespace linker { diff --git a/compiler/optimizing/bounds_check_elimination.cc b/compiler/optimizing/bounds_check_elimination.cc index f3ecdf036a..c166deb406 100644 --- a/compiler/optimizing/bounds_check_elimination.cc +++ b/compiler/optimizing/bounds_check_elimination.cc @@ -20,8 +20,8 @@ #include "base/arena_containers.h" #include "induction_var_range.h" -#include "side_effects_analysis.h" #include "nodes.h" +#include "side_effects_analysis.h" namespace art { diff --git a/compiler/optimizing/bounds_check_elimination_test.cc b/compiler/optimizing/bounds_check_elimination_test.cc index a949c33149..575e2fc24a 100644 --- a/compiler/optimizing/bounds_check_elimination_test.cc +++ b/compiler/optimizing/bounds_check_elimination_test.cc @@ -14,8 +14,9 @@ * limitations under the License. */ -#include "base/arena_allocator.h" #include "bounds_check_elimination.h" + +#include "base/arena_allocator.h" #include "builder.h" #include "gvn.h" #include "induction_var_analysis.h" diff --git a/compiler/optimizing/builder.h b/compiler/optimizing/builder.h index 3a4c9dbd16..43429cf3d2 100644 --- a/compiler/optimizing/builder.h +++ b/compiler/optimizing/builder.h @@ -20,14 +20,14 @@ #include "base/arena_containers.h" #include "base/arena_object.h" #include "block_builder.h" -#include "dex_file.h" #include "dex_file-inl.h" +#include "dex_file.h" #include "driver/compiler_driver.h" #include "driver/dex_compilation_unit.h" #include "instruction_builder.h" +#include "nodes.h" #include "optimizing_compiler_stats.h" #include "primitive.h" -#include "nodes.h" #include "ssa_builder.h" namespace art { diff --git a/compiler/optimizing/code_generator.cc b/compiler/optimizing/code_generator.cc index 2872cf7458..d7d0ffffda 100644 --- a/compiler/optimizing/code_generator.cc +++ b/compiler/optimizing/code_generator.cc @@ -57,8 +57,8 @@ #include "mirror/reference.h" #include "mirror/string.h" #include "parallel_move_resolver.h" -#include "ssa_liveness_analysis.h" #include "scoped_thread_state_change-inl.h" +#include "ssa_liveness_analysis.h" #include "thread-current-inl.h" #include "utils/assembler.h" diff --git a/compiler/optimizing/code_generator_arm64.cc b/compiler/optimizing/code_generator_arm64.cc index 7e5b1a0fd1..4999950600 100644 --- a/compiler/optimizing/code_generator_arm64.cc +++ b/compiler/optimizing/code_generator_arm64.cc @@ -29,9 +29,9 @@ #include "intrinsics.h" #include "intrinsics_arm64.h" #include "linker/arm64/relative_patcher_arm64.h" +#include "lock_word.h" #include "mirror/array-inl.h" #include "mirror/class-inl.h" -#include "lock_word.h" #include "offsets.h" #include "thread.h" #include "utils/arm64/assembler_arm64.h" diff --git a/compiler/optimizing/code_generator_arm_vixl.h b/compiler/optimizing/code_generator_arm_vixl.h index 01cf287f29..7ab2993161 100644 --- a/compiler/optimizing/code_generator_arm_vixl.h +++ b/compiler/optimizing/code_generator_arm_vixl.h @@ -22,8 +22,8 @@ #include "common_arm.h" #include "driver/compiler_options.h" #include "nodes.h" -#include "string_reference.h" #include "parallel_move_resolver.h" +#include "string_reference.h" #include "type_reference.h" #include "utils/arm/assembler_arm_vixl.h" diff --git a/compiler/optimizing/code_generator_x86.cc b/compiler/optimizing/code_generator_x86.cc index af0e6462a2..142cc7f71f 100644 --- a/compiler/optimizing/code_generator_x86.cc +++ b/compiler/optimizing/code_generator_x86.cc @@ -24,9 +24,9 @@ #include "gc/accounting/card_table.h" #include "intrinsics.h" #include "intrinsics_x86.h" +#include "lock_word.h" #include "mirror/array-inl.h" #include "mirror/class-inl.h" -#include "lock_word.h" #include "thread.h" #include "utils/assembler.h" #include "utils/stack_checks.h" diff --git a/compiler/optimizing/common_arm.h b/compiler/optimizing/common_arm.h index 8fcceedcf6..e354654ee8 100644 --- a/compiler/optimizing/common_arm.h +++ b/compiler/optimizing/common_arm.h @@ -17,8 +17,8 @@ #ifndef ART_COMPILER_OPTIMIZING_COMMON_ARM_H_ #define ART_COMPILER_OPTIMIZING_COMMON_ARM_H_ -#include "instruction_simplifier_shared.h" #include "debug/dwarf/register.h" +#include "instruction_simplifier_shared.h" #include "locations.h" #include "nodes.h" #include "utils/arm/constants_arm.h" diff --git a/compiler/optimizing/dead_code_elimination_test.cc b/compiler/optimizing/dead_code_elimination_test.cc index fdd77e7261..96fa5406b2 100644 --- a/compiler/optimizing/dead_code_elimination_test.cc +++ b/compiler/optimizing/dead_code_elimination_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "dead_code_elimination.h" + #include "arch/x86/instruction_set_features_x86.h" #include "code_generator_x86.h" -#include "dead_code_elimination.h" #include "driver/compiler_options.h" #include "graph_checker.h" #include "optimizing_unit_test.h" diff --git a/compiler/optimizing/find_loops_test.cc b/compiler/optimizing/find_loops_test.cc index 04789d9a2d..bbd28f5c46 100644 --- a/compiler/optimizing/find_loops_test.cc +++ b/compiler/optimizing/find_loops_test.cc @@ -20,8 +20,8 @@ #include "dex_instruction.h" #include "nodes.h" #include "optimizing_unit_test.h" -#include "ssa_liveness_analysis.h" #include "pretty_printer.h" +#include "ssa_liveness_analysis.h" #include "gtest/gtest.h" diff --git a/compiler/optimizing/graph_checker.cc b/compiler/optimizing/graph_checker.cc index aea901dec7..327e11f7e7 100644 --- a/compiler/optimizing/graph_checker.cc +++ b/compiler/optimizing/graph_checker.cc @@ -17,8 +17,8 @@ #include "graph_checker.h" #include <algorithm> -#include <string> #include <sstream> +#include <string> #include "android-base/stringprintf.h" diff --git a/compiler/optimizing/gvn_test.cc b/compiler/optimizing/gvn_test.cc index f8d37bd714..e1ed7f656e 100644 --- a/compiler/optimizing/gvn_test.cc +++ b/compiler/optimizing/gvn_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "gvn.h" + #include "base/arena_allocator.h" #include "builder.h" -#include "gvn.h" #include "nodes.h" #include "optimizing_unit_test.h" #include "side_effects_analysis.h" diff --git a/compiler/optimizing/induction_var_range_test.cc b/compiler/optimizing/induction_var_range_test.cc index 67d2093829..2b82b336d7 100644 --- a/compiler/optimizing/induction_var_range_test.cc +++ b/compiler/optimizing/induction_var_range_test.cc @@ -14,10 +14,11 @@ * limitations under the License. */ +#include "induction_var_range.h" + #include "base/arena_allocator.h" #include "builder.h" #include "induction_var_analysis.h" -#include "induction_var_range.h" #include "nodes.h" #include "optimizing_unit_test.h" diff --git a/compiler/optimizing/inliner.cc b/compiler/optimizing/inliner.cc index 18390cc4d4..38a1a8c024 100644 --- a/compiler/optimizing/inliner.cc +++ b/compiler/optimizing/inliner.cc @@ -23,8 +23,8 @@ #include "constant_folding.h" #include "dead_code_elimination.h" #include "dex/inline_method_analyser.h" -#include "dex/verified_method.h" #include "dex/verification_results.h" +#include "dex/verified_method.h" #include "driver/compiler_driver-inl.h" #include "driver/compiler_options.h" #include "driver/dex_compilation_unit.h" @@ -38,10 +38,10 @@ #include "optimizing_compiler.h" #include "reference_type_propagation.h" #include "register_allocator_linear_scan.h" +#include "scoped_thread_state_change-inl.h" #include "sharpening.h" #include "ssa_builder.h" #include "ssa_phi_elimination.h" -#include "scoped_thread_state_change-inl.h" #include "thread.h" namespace art { diff --git a/compiler/optimizing/inliner.h b/compiler/optimizing/inliner.h index 67476b6956..62c6713208 100644 --- a/compiler/optimizing/inliner.h +++ b/compiler/optimizing/inliner.h @@ -19,8 +19,8 @@ #include "dex_file_types.h" #include "invoke_type.h" -#include "optimization.h" #include "jit/profile_compilation_info.h" +#include "optimization.h" namespace art { diff --git a/compiler/optimizing/instruction_builder.cc b/compiler/optimizing/instruction_builder.cc index 8054140924..143c77f334 100644 --- a/compiler/optimizing/instruction_builder.cc +++ b/compiler/optimizing/instruction_builder.cc @@ -23,8 +23,8 @@ #include "driver/compiler_options.h" #include "imtable-inl.h" #include "quicken_info.h" -#include "sharpening.h" #include "scoped_thread_state_change-inl.h" +#include "sharpening.h" namespace art { diff --git a/compiler/optimizing/instruction_builder.h b/compiler/optimizing/instruction_builder.h index 5a83df3813..2a9b9f513d 100644 --- a/compiler/optimizing/instruction_builder.h +++ b/compiler/optimizing/instruction_builder.h @@ -21,8 +21,8 @@ #include "base/arena_object.h" #include "block_builder.h" #include "dex_file_types.h" -#include "driver/compiler_driver.h" #include "driver/compiler_driver-inl.h" +#include "driver/compiler_driver.h" #include "driver/dex_compilation_unit.h" #include "mirror/dex_cache.h" #include "nodes.h" diff --git a/compiler/optimizing/instruction_simplifier.cc b/compiler/optimizing/instruction_simplifier.cc index f2a8cc0333..02cfbbcfb3 100644 --- a/compiler/optimizing/instruction_simplifier.cc +++ b/compiler/optimizing/instruction_simplifier.cc @@ -21,8 +21,8 @@ #include "escape.h" #include "intrinsics.h" #include "mirror/class-inl.h" -#include "sharpening.h" #include "scoped_thread_state_change-inl.h" +#include "sharpening.h" namespace art { diff --git a/compiler/optimizing/instruction_simplifier_arm.cc b/compiler/optimizing/instruction_simplifier_arm.cc index a025fb10ce..a32d0ce42b 100644 --- a/compiler/optimizing/instruction_simplifier_arm.cc +++ b/compiler/optimizing/instruction_simplifier_arm.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "instruction_simplifier_arm.h" + #include "code_generator.h" #include "common_arm.h" -#include "instruction_simplifier_arm.h" #include "instruction_simplifier_shared.h" #include "mirror/array-inl.h" #include "mirror/string.h" diff --git a/compiler/optimizing/intrinsics.cc b/compiler/optimizing/intrinsics.cc index b664d41013..7bdeef527e 100644 --- a/compiler/optimizing/intrinsics.cc +++ b/compiler/optimizing/intrinsics.cc @@ -39,7 +39,7 @@ static inline InvokeType GetIntrinsicInvokeType(Intrinsics i) { case Intrinsics::k ## Name: \ return IsStatic; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS } @@ -55,7 +55,7 @@ static inline IntrinsicNeedsEnvironmentOrCache NeedsEnvironmentOrCache(Intrinsic case Intrinsics::k ## Name: \ return NeedsEnvironmentOrCache; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS } @@ -71,7 +71,7 @@ static inline IntrinsicSideEffects GetSideEffects(Intrinsics i) { case Intrinsics::k ## Name: \ return SideEffects; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS } @@ -87,7 +87,7 @@ static inline IntrinsicExceptions GetExceptions(Intrinsics i) { case Intrinsics::k ## Name: \ return Exceptions; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS } @@ -172,7 +172,7 @@ std::ostream& operator<<(std::ostream& os, const Intrinsics& intrinsic) { os << # Name; \ break; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef STATIC_INTRINSICS_LIST #undef VIRTUAL_INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics.h b/compiler/optimizing/intrinsics.h index 9da5a7fa3b..6411e82f92 100644 --- a/compiler/optimizing/intrinsics.h +++ b/compiler/optimizing/intrinsics.h @@ -63,7 +63,7 @@ class IntrinsicVisitor : public ValueObject { Visit ## Name(invoke); \ return; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -77,7 +77,7 @@ INTRINSICS_LIST(OPTIMIZING_INTRINSICS) virtual void Visit ## Name(HInvoke* invoke ATTRIBUTE_UNUSED) { \ } #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_arm64.h b/compiler/optimizing/intrinsics_arm64.h index ff59ce9658..5a6d180ed6 100644 --- a/compiler/optimizing/intrinsics_arm64.h +++ b/compiler/optimizing/intrinsics_arm64.h @@ -47,7 +47,7 @@ class IntrinsicLocationsBuilderARM64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -72,7 +72,7 @@ class IntrinsicCodeGeneratorARM64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_arm_vixl.h b/compiler/optimizing/intrinsics_arm_vixl.h index 023cba1349..a4a2830211 100644 --- a/compiler/optimizing/intrinsics_arm_vixl.h +++ b/compiler/optimizing/intrinsics_arm_vixl.h @@ -36,7 +36,7 @@ class IntrinsicLocationsBuilderARMVIXL FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -63,7 +63,7 @@ class IntrinsicCodeGeneratorARMVIXL FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_mips.h b/compiler/optimizing/intrinsics_mips.h index eaadad2515..05d1aa284a 100644 --- a/compiler/optimizing/intrinsics_mips.h +++ b/compiler/optimizing/intrinsics_mips.h @@ -39,7 +39,7 @@ class IntrinsicLocationsBuilderMIPS FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -64,7 +64,7 @@ class IntrinsicCodeGeneratorMIPS FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_mips64.h b/compiler/optimizing/intrinsics_mips64.h index 179627ab20..6880a255c3 100644 --- a/compiler/optimizing/intrinsics_mips64.h +++ b/compiler/optimizing/intrinsics_mips64.h @@ -39,7 +39,7 @@ class IntrinsicLocationsBuilderMIPS64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -64,7 +64,7 @@ class IntrinsicCodeGeneratorMIPS64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_x86.h b/compiler/optimizing/intrinsics_x86.h index 3743cb1371..22f11b1d34 100644 --- a/compiler/optimizing/intrinsics_x86.h +++ b/compiler/optimizing/intrinsics_x86.h @@ -39,7 +39,7 @@ class IntrinsicLocationsBuilderX86 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -64,7 +64,7 @@ class IntrinsicCodeGeneratorX86 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/intrinsics_x86_64.h b/compiler/optimizing/intrinsics_x86_64.h index 97404aa568..4b287886af 100644 --- a/compiler/optimizing/intrinsics_x86_64.h +++ b/compiler/optimizing/intrinsics_x86_64.h @@ -39,7 +39,7 @@ class IntrinsicLocationsBuilderX86_64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS @@ -64,7 +64,7 @@ class IntrinsicCodeGeneratorX86_64 FINAL : public IntrinsicVisitor { #define OPTIMIZING_INTRINSICS(Name, IsStatic, NeedsEnvironmentOrCache, SideEffects, Exceptions, ...) \ void Visit ## Name(HInvoke* invoke) OVERRIDE; #include "intrinsics_list.h" -INTRINSICS_LIST(OPTIMIZING_INTRINSICS) + INTRINSICS_LIST(OPTIMIZING_INTRINSICS) #undef INTRINSICS_LIST #undef OPTIMIZING_INTRINSICS diff --git a/compiler/optimizing/licm_test.cc b/compiler/optimizing/licm_test.cc index 8d15f78cce..8967d7cef2 100644 --- a/compiler/optimizing/licm_test.cc +++ b/compiler/optimizing/licm_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ +#include "licm.h" + #include "base/arena_allocator.h" #include "builder.h" -#include "licm.h" #include "nodes.h" #include "optimizing_unit_test.h" #include "side_effects_analysis.h" diff --git a/compiler/optimizing/load_store_elimination.cc b/compiler/optimizing/load_store_elimination.cc index 211528b4bd..fddda3d8c0 100644 --- a/compiler/optimizing/load_store_elimination.cc +++ b/compiler/optimizing/load_store_elimination.cc @@ -14,10 +14,10 @@ * limitations under the License. */ -#include "load_store_analysis.h" #include "load_store_elimination.h" #include "escape.h" +#include "load_store_analysis.h" #include "side_effects_analysis.h" #include <iostream> diff --git a/compiler/optimizing/locations.cc b/compiler/optimizing/locations.cc index a9fe209063..40fe35b31b 100644 --- a/compiler/optimizing/locations.cc +++ b/compiler/optimizing/locations.cc @@ -18,8 +18,8 @@ #include <type_traits> -#include "nodes.h" #include "code_generator.h" +#include "nodes.h" namespace art { diff --git a/compiler/optimizing/loop_optimization.cc b/compiler/optimizing/loop_optimization.cc index 422e58debb..274f065084 100644 --- a/compiler/optimizing/loop_optimization.cc +++ b/compiler/optimizing/loop_optimization.cc @@ -16,9 +16,9 @@ #include "loop_optimization.h" -#include "arch/instruction_set.h" #include "arch/arm/instruction_set_features_arm.h" #include "arch/arm64/instruction_set_features_arm64.h" +#include "arch/instruction_set.h" #include "arch/mips/instruction_set_features_mips.h" #include "arch/mips64/instruction_set_features_mips64.h" #include "arch/x86/instruction_set_features_x86.h" diff --git a/compiler/optimizing/nodes.cc b/compiler/optimizing/nodes.cc index 4ca833707b..ca48e08a7c 100644 --- a/compiler/optimizing/nodes.cc +++ b/compiler/optimizing/nodes.cc @@ -18,16 +18,16 @@ #include <cfloat> #include "art_method-inl.h" +#include "base/bit_utils.h" +#include "base/bit_vector-inl.h" +#include "base/stl_util.h" #include "class_linker-inl.h" #include "code_generator.h" #include "common_dominator.h" -#include "ssa_builder.h" -#include "base/bit_vector-inl.h" -#include "base/bit_utils.h" -#include "base/stl_util.h" #include "intrinsics.h" #include "mirror/class-inl.h" #include "scoped_thread_state_change-inl.h" +#include "ssa_builder.h" namespace art { diff --git a/compiler/optimizing/nodes.h b/compiler/optimizing/nodes.h index 5e072cdb67..fa29378e42 100644 --- a/compiler/optimizing/nodes.h +++ b/compiler/optimizing/nodes.h @@ -28,14 +28,14 @@ #include "base/iteration_range.h" #include "base/stl_util.h" #include "base/transform_array_ref.h" +#include "deoptimization_kind.h" #include "dex_file.h" #include "dex_file_types.h" -#include "deoptimization_kind.h" #include "entrypoints/quick/quick_entrypoints_enum.h" #include "handle.h" #include "handle_scope.h" -#include "invoke_type.h" #include "intrinsics_enum.h" +#include "invoke_type.h" #include "locations.h" #include "method_reference.h" #include "mirror/class.h" diff --git a/compiler/optimizing/nodes_shared.cc b/compiler/optimizing/nodes_shared.cc index f145bf9130..f6d33f015f 100644 --- a/compiler/optimizing/nodes_shared.cc +++ b/compiler/optimizing/nodes_shared.cc @@ -14,9 +14,15 @@ * limitations under the License. */ -#include "common_arm64.h" +// Note: this include order may seem strange and is against the regular style. However it is the +// required order as nodes_shared does not have the right dependency chain and compilation +// will fail (as AsType on HInstruction will be defined before the full Instruction). +#include "nodes.h" + #include "nodes_shared.h" +#include "common_arm64.h" + namespace art { using helpers::CanFitInShifterOperand; diff --git a/compiler/optimizing/nodes_test.cc b/compiler/optimizing/nodes_test.cc index 7686ba851b..f3a78a064e 100644 --- a/compiler/optimizing/nodes_test.cc +++ b/compiler/optimizing/nodes_test.cc @@ -14,8 +14,9 @@ * limitations under the License. */ -#include "base/arena_allocator.h" #include "nodes.h" + +#include "base/arena_allocator.h" #include "optimizing_unit_test.h" #include "gtest/gtest.h" diff --git a/compiler/optimizing/optimizing_cfi_test.cc b/compiler/optimizing/optimizing_cfi_test.cc index 6cb27b3b1b..c24f1de93d 100644 --- a/compiler/optimizing/optimizing_cfi_test.cc +++ b/compiler/optimizing/optimizing_cfi_test.cc @@ -23,8 +23,8 @@ #include "gtest/gtest.h" #include "optimizing/code_generator.h" #include "optimizing/optimizing_unit_test.h" -#include "utils/assembler.h" #include "utils/arm/assembler_arm_vixl.h" +#include "utils/assembler.h" #include "utils/mips/assembler_mips.h" #include "utils/mips64/assembler_mips64.h" diff --git a/compiler/optimizing/optimizing_compiler.cc b/compiler/optimizing/optimizing_compiler.cc index b76a0df861..51101f104a 100644 --- a/compiler/optimizing/optimizing_compiler.cc +++ b/compiler/optimizing/optimizing_compiler.cc @@ -87,8 +87,8 @@ #include "prepare_for_register_allocation.h" #include "reference_type_propagation.h" #include "register_allocator_linear_scan.h" -#include "select_generator.h" #include "scheduler.h" +#include "select_generator.h" #include "sharpening.h" #include "side_effects_analysis.h" #include "ssa_builder.h" diff --git a/compiler/optimizing/optimizing_unit_test.h b/compiler/optimizing/optimizing_unit_test.h index 1cdcbd2e9b..08493fa177 100644 --- a/compiler/optimizing/optimizing_unit_test.h +++ b/compiler/optimizing/optimizing_unit_test.h @@ -17,12 +17,12 @@ #ifndef ART_COMPILER_OPTIMIZING_OPTIMIZING_UNIT_TEST_H_ #define ART_COMPILER_OPTIMIZING_OPTIMIZING_UNIT_TEST_H_ -#include "nodes.h" #include "builder.h" #include "common_compiler_test.h" #include "dex_file.h" #include "dex_instruction.h" #include "handle_scope.h" +#include "nodes.h" #include "scoped_thread_state_change.h" #include "ssa_builder.h" #include "ssa_liveness_analysis.h" diff --git a/compiler/optimizing/parallel_move_test.cc b/compiler/optimizing/parallel_move_test.cc index 5e8fe37669..50620f0e7b 100644 --- a/compiler/optimizing/parallel_move_test.cc +++ b/compiler/optimizing/parallel_move_test.cc @@ -18,8 +18,8 @@ #include "nodes.h" #include "parallel_move_resolver.h" -#include "gtest/gtest.h" #include "gtest/gtest-typed-test.h" +#include "gtest/gtest.h" namespace art { diff --git a/compiler/optimizing/pretty_printer_test.cc b/compiler/optimizing/pretty_printer_test.cc index 1af94f3445..14d2360392 100644 --- a/compiler/optimizing/pretty_printer_test.cc +++ b/compiler/optimizing/pretty_printer_test.cc @@ -14,13 +14,14 @@ * limitations under the License. */ +#include "pretty_printer.h" + #include "base/arena_allocator.h" #include "builder.h" #include "dex_file.h" #include "dex_instruction.h" #include "nodes.h" #include "optimizing_unit_test.h" -#include "pretty_printer.h" #include "gtest/gtest.h" diff --git a/compiler/optimizing/reference_type_propagation_test.cc b/compiler/optimizing/reference_type_propagation_test.cc index 0b49ce1a4c..d537459113 100644 --- a/compiler/optimizing/reference_type_propagation_test.cc +++ b/compiler/optimizing/reference_type_propagation_test.cc @@ -14,12 +14,13 @@ * limitations under the License. */ +#include "reference_type_propagation.h" + #include "base/arena_allocator.h" #include "builder.h" #include "nodes.h" #include "object_lock.h" #include "optimizing_unit_test.h" -#include "reference_type_propagation.h" namespace art { diff --git a/compiler/optimizing/register_allocator.cc b/compiler/optimizing/register_allocator.cc index 5b768d5d67..c3b33e29d7 100644 --- a/compiler/optimizing/register_allocator.cc +++ b/compiler/optimizing/register_allocator.cc @@ -25,7 +25,6 @@ #include "register_allocator_linear_scan.h" #include "ssa_liveness_analysis.h" - namespace art { RegisterAllocator::RegisterAllocator(ArenaAllocator* allocator, diff --git a/compiler/optimizing/register_allocator_test.cc b/compiler/optimizing/register_allocator_test.cc index 24a2ab24d8..bcdd7f9cd8 100644 --- a/compiler/optimizing/register_allocator_test.cc +++ b/compiler/optimizing/register_allocator_test.cc @@ -14,6 +14,8 @@ * limitations under the License. */ +#include "register_allocator.h" + #include "arch/x86/instruction_set_features_x86.h" #include "base/arena_allocator.h" #include "builder.h" @@ -25,7 +27,6 @@ #include "driver/compiler_options.h" #include "nodes.h" #include "optimizing_unit_test.h" -#include "register_allocator.h" #include "register_allocator_linear_scan.h" #include "ssa_liveness_analysis.h" #include "ssa_phi_elimination.h" diff --git a/compiler/optimizing/scheduler.h b/compiler/optimizing/scheduler.h index 930a2c82cf..66ffac5b7d 100644 --- a/compiler/optimizing/scheduler.h +++ b/compiler/optimizing/scheduler.h @@ -20,11 +20,11 @@ #include <fstream> #include "base/time_utils.h" +#include "code_generator.h" #include "driver/compiler_driver.h" #include "load_store_analysis.h" #include "nodes.h" #include "optimization.h" -#include "code_generator.h" namespace art { diff --git a/compiler/optimizing/scheduler_arm.cc b/compiler/optimizing/scheduler_arm.cc index f025c0a2d4..ea15790105 100644 --- a/compiler/optimizing/scheduler_arm.cc +++ b/compiler/optimizing/scheduler_arm.cc @@ -14,11 +14,12 @@ * limitations under the License. */ +#include "scheduler_arm.h" + #include "arch/arm/instruction_set_features_arm.h" #include "code_generator_utils.h" #include "common_arm.h" #include "mirror/array-inl.h" -#include "scheduler_arm.h" namespace art { namespace arm { diff --git a/compiler/optimizing/scheduler_arm64.cc b/compiler/optimizing/scheduler_arm64.cc index 83b487fb5b..f54d3f3de2 100644 --- a/compiler/optimizing/scheduler_arm64.cc +++ b/compiler/optimizing/scheduler_arm64.cc @@ -15,6 +15,7 @@ */ #include "scheduler_arm64.h" + #include "code_generator_utils.h" #include "mirror/array-inl.h" diff --git a/compiler/optimizing/scheduler_test.cc b/compiler/optimizing/scheduler_test.cc index 10c3cd7535..cdb6666f83 100644 --- a/compiler/optimizing/scheduler_test.cc +++ b/compiler/optimizing/scheduler_test.cc @@ -14,6 +14,8 @@ * limitations under the License. */ +#include "scheduler.h" + #include "base/arena_allocator.h" #include "builder.h" #include "codegen_test_utils.h" @@ -23,7 +25,6 @@ #include "optimizing_unit_test.h" #include "pc_relative_fixups_x86.h" #include "register_allocator.h" -#include "scheduler.h" #ifdef ART_ENABLE_CODEGEN_arm64 #include "scheduler_arm64.h" diff --git a/compiler/optimizing/sharpening.cc b/compiler/optimizing/sharpening.cc index 8bd568befd..9536d149f6 100644 --- a/compiler/optimizing/sharpening.cc +++ b/compiler/optimizing/sharpening.cc @@ -21,10 +21,9 @@ #include "base/enums.h" #include "class_linker.h" #include "code_generator.h" +#include "driver/compiler_driver.h" #include "driver/compiler_options.h" #include "driver/dex_compilation_unit.h" -#include "utils/dex_cache_arrays_layout-inl.h" -#include "driver/compiler_driver.h" #include "gc/heap.h" #include "gc/space/image_space.h" #include "handle_scope-inl.h" @@ -33,6 +32,7 @@ #include "nodes.h" #include "runtime.h" #include "scoped_thread_state_change-inl.h" +#include "utils/dex_cache_arrays_layout-inl.h" namespace art { diff --git a/compiler/optimizing/ssa_liveness_analysis_test.cc b/compiler/optimizing/ssa_liveness_analysis_test.cc index 029eb4ba61..b46060a24a 100644 --- a/compiler/optimizing/ssa_liveness_analysis_test.cc +++ b/compiler/optimizing/ssa_liveness_analysis_test.cc @@ -14,15 +14,16 @@ * limitations under the License. */ +#include "ssa_liveness_analysis.h" + #include "arch/instruction_set.h" #include "arch/instruction_set_features.h" #include "base/arena_allocator.h" #include "base/arena_containers.h" -#include "driver/compiler_options.h" #include "code_generator.h" +#include "driver/compiler_options.h" #include "nodes.h" #include "optimizing_unit_test.h" -#include "ssa_liveness_analysis.h" namespace art { diff --git a/compiler/optimizing/ssa_phi_elimination.cc b/compiler/optimizing/ssa_phi_elimination.cc index aec7a3c555..b4f8408a76 100644 --- a/compiler/optimizing/ssa_phi_elimination.cc +++ b/compiler/optimizing/ssa_phi_elimination.cc @@ -16,8 +16,8 @@ #include "ssa_phi_elimination.h" -#include "base/arena_containers.h" #include "base/arena_bit_vector.h" +#include "base/arena_containers.h" #include "base/bit_vector-inl.h" namespace art { diff --git a/compiler/utils/arm/jni_macro_assembler_arm_vixl.cc b/compiler/utils/arm/jni_macro_assembler_arm_vixl.cc index bebe64c2b9..ed57ca68e2 100644 --- a/compiler/utils/arm/jni_macro_assembler_arm_vixl.cc +++ b/compiler/utils/arm/jni_macro_assembler_arm_vixl.cc @@ -14,10 +14,11 @@ * limitations under the License. */ +#include "jni_macro_assembler_arm_vixl.h" + #include <iostream> #include <type_traits> -#include "jni_macro_assembler_arm_vixl.h" #include "entrypoints/quick/quick_entrypoints.h" #include "thread.h" diff --git a/compiler/utils/arm/managed_register_arm_test.cc b/compiler/utils/arm/managed_register_arm_test.cc index f5d4cc0d10..43b0b516dc 100644 --- a/compiler/utils/arm/managed_register_arm_test.cc +++ b/compiler/utils/arm/managed_register_arm_test.cc @@ -14,8 +14,8 @@ * limitations under the License. */ -#include "globals.h" #include "managed_register_arm.h" +#include "globals.h" #include "gtest/gtest.h" namespace art { diff --git a/compiler/utils/arm64/assembler_arm64.h b/compiler/utils/arm64/assembler_arm64.h index 66a7fed804..5b8a34e56d 100644 --- a/compiler/utils/arm64/assembler_arm64.h +++ b/compiler/utils/arm64/assembler_arm64.h @@ -23,9 +23,9 @@ #include "base/arena_containers.h" #include "base/logging.h" +#include "offsets.h" #include "utils/arm64/managed_register_arm64.h" #include "utils/assembler.h" -#include "offsets.h" // TODO(VIXL): Make VIXL compile with -Wshadow. #pragma GCC diagnostic push diff --git a/compiler/utils/arm64/jni_macro_assembler_arm64.h b/compiler/utils/arm64/jni_macro_assembler_arm64.h index 264e99adab..baf0434de0 100644 --- a/compiler/utils/arm64/jni_macro_assembler_arm64.h +++ b/compiler/utils/arm64/jni_macro_assembler_arm64.h @@ -25,9 +25,9 @@ #include "base/arena_containers.h" #include "base/enums.h" #include "base/logging.h" +#include "offsets.h" #include "utils/assembler.h" #include "utils/jni_macro_assembler.h" -#include "offsets.h" // TODO(VIXL): Make VIXL compile with -Wshadow. #pragma GCC diagnostic push diff --git a/compiler/utils/arm64/managed_register_arm64_test.cc b/compiler/utils/arm64/managed_register_arm64_test.cc index 79076b8ccc..2a79313be5 100644 --- a/compiler/utils/arm64/managed_register_arm64_test.cc +++ b/compiler/utils/arm64/managed_register_arm64_test.cc @@ -14,9 +14,10 @@ * limitations under the License. */ -#include "globals.h" -#include "assembler_arm64.h" #include "managed_register_arm64.h" + +#include "assembler_arm64.h" +#include "globals.h" #include "gtest/gtest.h" namespace art { diff --git a/compiler/utils/assembler_test.h b/compiler/utils/assembler_test.h index f655994bd3..ef53d7237c 100644 --- a/compiler/utils/assembler_test.h +++ b/compiler/utils/assembler_test.h @@ -19,14 +19,15 @@ #include "assembler.h" -#include "assembler_test_base.h" -#include "common_runtime_test.h" // For ScratchFile +#include <sys/stat.h> #include <cstdio> #include <cstdlib> #include <fstream> #include <iterator> -#include <sys/stat.h> + +#include "assembler_test_base.h" +#include "common_runtime_test.h" // For ScratchFile namespace art { diff --git a/compiler/utils/assembler_test_base.h b/compiler/utils/assembler_test_base.h index d76cb1c1df..2ef43bd79c 100644 --- a/compiler/utils/assembler_test_base.h +++ b/compiler/utils/assembler_test_base.h @@ -17,11 +17,11 @@ #ifndef ART_COMPILER_UTILS_ASSEMBLER_TEST_BASE_H_ #define ART_COMPILER_UTILS_ASSEMBLER_TEST_BASE_H_ +#include <sys/stat.h> #include <cstdio> #include <cstdlib> #include <fstream> #include <iterator> -#include <sys/stat.h> #include "android-base/strings.h" diff --git a/compiler/utils/assembler_thumb_test.cc b/compiler/utils/assembler_thumb_test.cc index 741beab1d5..e51b622b81 100644 --- a/compiler/utils/assembler_thumb_test.cc +++ b/compiler/utils/assembler_thumb_test.cc @@ -16,10 +16,10 @@ #include <dirent.h> #include <errno.h> -#include <fstream> -#include <map> #include <string.h> #include <sys/types.h> +#include <fstream> +#include <map> #include "gtest/gtest.h" diff --git a/compiler/utils/dedupe_set-inl.h b/compiler/utils/dedupe_set-inl.h index c06e9cadcc..c866504e62 100644 --- a/compiler/utils/dedupe_set-inl.h +++ b/compiler/utils/dedupe_set-inl.h @@ -19,14 +19,15 @@ #include "dedupe_set.h" -#include <algorithm> #include <inttypes.h> + +#include <algorithm> #include <unordered_map> #include "android-base/stringprintf.h" -#include "base/mutex.h" #include "base/hash_set.h" +#include "base/mutex.h" #include "base/stl_util.h" #include "base/time_utils.h" diff --git a/compiler/utils/dedupe_set.h b/compiler/utils/dedupe_set.h index b62f216842..3baa0612f6 100644 --- a/compiler/utils/dedupe_set.h +++ b/compiler/utils/dedupe_set.h @@ -17,8 +17,8 @@ #ifndef ART_COMPILER_UTILS_DEDUPE_SET_H_ #define ART_COMPILER_UTILS_DEDUPE_SET_H_ -#include <memory> #include <stdint.h> +#include <memory> #include <string> #include "base/macros.h" diff --git a/compiler/utils/jni_macro_assembler_test.h b/compiler/utils/jni_macro_assembler_test.h index 293f4cde9c..61296802f8 100644 --- a/compiler/utils/jni_macro_assembler_test.h +++ b/compiler/utils/jni_macro_assembler_test.h @@ -22,11 +22,12 @@ #include "assembler_test_base.h" #include "common_runtime_test.h" // For ScratchFile +#include <sys/stat.h> + #include <cstdio> #include <cstdlib> #include <fstream> #include <iterator> -#include <sys/stat.h> namespace art { diff --git a/compiler/utils/swap_space.cc b/compiler/utils/swap_space.cc index 621a652f0a..12d113d420 100644 --- a/compiler/utils/swap_space.cc +++ b/compiler/utils/swap_space.cc @@ -16,9 +16,10 @@ #include "swap_space.h" +#include <sys/mman.h> + #include <algorithm> #include <numeric> -#include <sys/mman.h> #include "base/bit_utils.h" #include "base/logging.h" diff --git a/compiler/utils/swap_space.h b/compiler/utils/swap_space.h index 0ff9fc69ed..08e243b644 100644 --- a/compiler/utils/swap_space.h +++ b/compiler/utils/swap_space.h @@ -17,12 +17,12 @@ #ifndef ART_COMPILER_UTILS_SWAP_SPACE_H_ #define ART_COMPILER_UTILS_SWAP_SPACE_H_ +#include <stddef.h> +#include <stdint.h> #include <cstdlib> #include <list> -#include <vector> #include <set> -#include <stdint.h> -#include <stddef.h> +#include <vector> #include "base/logging.h" #include "base/macros.h" diff --git a/compiler/utils/swap_space_test.cc b/compiler/utils/swap_space_test.cc index bf50ac3209..f4bca59cb3 100644 --- a/compiler/utils/swap_space_test.cc +++ b/compiler/utils/swap_space_test.cc @@ -16,10 +16,12 @@ #include "utils/swap_space.h" -#include <cstdio> -#include <sys/types.h> -#include <sys/stat.h> #include <fcntl.h> +#include <sys/stat.h> +#include <sys/types.h> + +#include <cstdio> + #include "gtest/gtest.h" #include "base/unix_file/fd_file.h" diff --git a/compiler/utils/test_dex_file_builder.h b/compiler/utils/test_dex_file_builder.h index 6921780a85..9ba3903033 100644 --- a/compiler/utils/test_dex_file_builder.h +++ b/compiler/utils/test_dex_file_builder.h @@ -17,11 +17,12 @@ #ifndef ART_COMPILER_UTILS_TEST_DEX_FILE_BUILDER_H_ #define ART_COMPILER_UTILS_TEST_DEX_FILE_BUILDER_H_ +#include <zlib.h> + #include <cstring> -#include <set> #include <map> +#include <set> #include <vector> -#include <zlib.h> #include "base/bit_utils.h" #include "base/logging.h" diff --git a/compiler/utils/x86/jni_macro_assembler_x86.cc b/compiler/utils/x86/jni_macro_assembler_x86.cc index cfdf80ba50..e074346e01 100644 --- a/compiler/utils/x86/jni_macro_assembler_x86.cc +++ b/compiler/utils/x86/jni_macro_assembler_x86.cc @@ -16,10 +16,10 @@ #include "jni_macro_assembler_x86.h" -#include "utils/assembler.h" #include "base/casts.h" #include "entrypoints/quick/quick_entrypoints.h" #include "thread.h" +#include "utils/assembler.h" namespace art { namespace x86 { diff --git a/compiler/utils/x86/managed_register_x86_test.cc b/compiler/utils/x86/managed_register_x86_test.cc index 4fbafdadf9..0ed5c36fe4 100644 --- a/compiler/utils/x86/managed_register_x86_test.cc +++ b/compiler/utils/x86/managed_register_x86_test.cc @@ -14,8 +14,9 @@ * limitations under the License. */ -#include "globals.h" #include "managed_register_x86.h" + +#include "globals.h" #include "gtest/gtest.h" namespace art { diff --git a/compiler/utils/x86_64/managed_register_x86_64_test.cc b/compiler/utils/x86_64/managed_register_x86_64_test.cc index 2dc7581472..e43d717385 100644 --- a/compiler/utils/x86_64/managed_register_x86_64_test.cc +++ b/compiler/utils/x86_64/managed_register_x86_64_test.cc @@ -14,8 +14,8 @@ * limitations under the License. */ -#include "globals.h" #include "managed_register_x86_64.h" +#include "globals.h" #include "gtest/gtest.h" namespace art { |