SConscript revision 5628
12929Sktlim@umich.edu# -*- mode:python -*-
22929Sktlim@umich.edu
32932Sktlim@umich.edu# Copyright (c) 2005-2006 The Regents of The University of Michigan
42929Sktlim@umich.edu# All rights reserved.
52929Sktlim@umich.edu#
62929Sktlim@umich.edu# Redistribution and use in source and binary forms, with or without
72929Sktlim@umich.edu# modification, are permitted provided that the following conditions are
82929Sktlim@umich.edu# met: redistributions of source code must retain the above copyright
92929Sktlim@umich.edu# notice, this list of conditions and the following disclaimer;
102929Sktlim@umich.edu# redistributions in binary form must reproduce the above copyright
112929Sktlim@umich.edu# notice, this list of conditions and the following disclaimer in the
122929Sktlim@umich.edu# documentation and/or other materials provided with the distribution;
132929Sktlim@umich.edu# neither the name of the copyright holders nor the names of its
142929Sktlim@umich.edu# contributors may be used to endorse or promote products derived from
152929Sktlim@umich.edu# this software without specific prior written permission.
162929Sktlim@umich.edu#
172929Sktlim@umich.edu# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
182929Sktlim@umich.edu# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
192929Sktlim@umich.edu# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
202929Sktlim@umich.edu# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
212929Sktlim@umich.edu# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
222929Sktlim@umich.edu# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
232929Sktlim@umich.edu# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
242929Sktlim@umich.edu# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
252929Sktlim@umich.edu# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
262929Sktlim@umich.edu# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
272929Sktlim@umich.edu# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
282932Sktlim@umich.edu#
292932Sktlim@umich.edu# Authors: Gabe Black
302932Sktlim@umich.edu
312929Sktlim@umich.edu# Copyright (c) 2007-2008 The Hewlett-Packard Development Company
326007Ssteve.reinhardt@amd.com# All rights reserved.
332929Sktlim@umich.edu#
342929Sktlim@umich.edu# Redistribution and use of this software in source and binary forms,
352929Sktlim@umich.edu# with or without modification, are permitted provided that the
362929Sktlim@umich.edu# following conditions are met:
372929Sktlim@umich.edu#
382929Sktlim@umich.edu# The software must be used only for Non-Commercial Use which means any
392929Sktlim@umich.edu# use which is NOT directed to receiving any direct monetary
402929Sktlim@umich.edu# compensation for, or commercial advantage from such use.  Illustrative
412929Sktlim@umich.edu# examples of non-commercial use are academic research, personal study,
422929Sktlim@umich.edu# teaching, education and corporate research & development.
432929Sktlim@umich.edu# Illustrative examples of commercial use are distributing products for
442929Sktlim@umich.edu# commercial advantage and providing services using the software for
452929Sktlim@umich.edu# commercial advantage.
462929Sktlim@umich.edu#
476007Ssteve.reinhardt@amd.com# If you wish to use this software or functionality therein that may be
486007Ssteve.reinhardt@amd.com# covered by patents for commercial use, please contact:
496007Ssteve.reinhardt@amd.com#     Director of Intellectual Property Licensing
506007Ssteve.reinhardt@amd.com#     Office of Strategy and Technology
516007Ssteve.reinhardt@amd.com#     Hewlett-Packard Company
526007Ssteve.reinhardt@amd.com#     1501 Page Mill Road
536007Ssteve.reinhardt@amd.com#     Palo Alto, California  94304
546007Ssteve.reinhardt@amd.com#
556007Ssteve.reinhardt@amd.com# Redistributions of source code must retain the above copyright notice,
566007Ssteve.reinhardt@amd.com# this list of conditions and the following disclaimer.  Redistributions
576007Ssteve.reinhardt@amd.com# in binary form must reproduce the above copyright notice, this list of
586007Ssteve.reinhardt@amd.com# conditions and the following disclaimer in the documentation and/or
596007Ssteve.reinhardt@amd.com# other materials provided with the distribution.  Neither the name of
606007Ssteve.reinhardt@amd.com# the COPYRIGHT HOLDER(s), HEWLETT-PACKARD COMPANY, nor the names of its
616007Ssteve.reinhardt@amd.com# contributors may be used to endorse or promote products derived from
626007Ssteve.reinhardt@amd.com# this software without specific prior written permission.  No right of
636007Ssteve.reinhardt@amd.com# sublicense is granted herewith.  Derivatives of the software and
646007Ssteve.reinhardt@amd.com# output created using the software may be prepared, but only for
656007Ssteve.reinhardt@amd.com# Non-Commercial Uses.  Derivatives of the software may be shared with
666007Ssteve.reinhardt@amd.com# others provided: (i) the others agree to abide by the list of
676007Ssteve.reinhardt@amd.com# conditions herein which includes the Non-Commercial Use restrictions;
686007Ssteve.reinhardt@amd.com# and (ii) such Derivatives of the software include the above copyright
696007Ssteve.reinhardt@amd.com# notice to acknowledge the contribution from this software where
706007Ssteve.reinhardt@amd.com# applicable, this list of conditions and the disclaimer below.
716007Ssteve.reinhardt@amd.com#
726007Ssteve.reinhardt@amd.com# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
736007Ssteve.reinhardt@amd.com# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
746007Ssteve.reinhardt@amd.com# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
756007Ssteve.reinhardt@amd.com# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
762929Sktlim@umich.edu# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
772929Sktlim@umich.edu# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
782929Sktlim@umich.edu# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
796007Ssteve.reinhardt@amd.com# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
806007Ssteve.reinhardt@amd.com# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
816007Ssteve.reinhardt@amd.com# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
826007Ssteve.reinhardt@amd.com# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
836007Ssteve.reinhardt@amd.com#
846007Ssteve.reinhardt@amd.com# Authors: Gabe Black
852929Sktlim@umich.edu
862929Sktlim@umich.eduImport('*')
872929Sktlim@umich.edu
882929Sktlim@umich.eduif env['TARGET_ISA'] == 'x86':
892929Sktlim@umich.edu    Source('emulenv.cc')
906011Ssteve.reinhardt@amd.com    Source('floatregfile.cc')
916007Ssteve.reinhardt@amd.com    Source('faults.cc')
926007Ssteve.reinhardt@amd.com    Source('insts/microfpop.cc')
936007Ssteve.reinhardt@amd.com    Source('insts/microldstop.cc')
946007Ssteve.reinhardt@amd.com    Source('insts/microop.cc')
956007Ssteve.reinhardt@amd.com    Source('insts/microregop.cc')
966007Ssteve.reinhardt@amd.com    Source('insts/static_inst.cc')
976007Ssteve.reinhardt@amd.com    Source('intregfile.cc')
986007Ssteve.reinhardt@amd.com    Source('miscregfile.cc')
996007Ssteve.reinhardt@amd.com    Source('pagetable.cc')
1006007Ssteve.reinhardt@amd.com    Source('predecoder.cc')
1016007Ssteve.reinhardt@amd.com    Source('predecoder_tables.cc')
1026007Ssteve.reinhardt@amd.com    Source('regfile.cc')
1036007Ssteve.reinhardt@amd.com    Source('remote_gdb.cc')
1046007Ssteve.reinhardt@amd.com    Source('tlb.cc')
1056011Ssteve.reinhardt@amd.com    Source('utility.cc')
1066007Ssteve.reinhardt@amd.com
1076007Ssteve.reinhardt@amd.com    SimObject('X86TLB.py')
1086007Ssteve.reinhardt@amd.com    TraceFlag('Predecoder')
1096007Ssteve.reinhardt@amd.com    TraceFlag('X86')
1106007Ssteve.reinhardt@amd.com
1116007Ssteve.reinhardt@amd.com    if env['FULL_SYSTEM']:
1126007Ssteve.reinhardt@amd.com        SimObject('X86System.py')
1136011Ssteve.reinhardt@amd.com
1146007Ssteve.reinhardt@amd.com        # Full-system sources
1156007Ssteve.reinhardt@amd.com        Source('linux/system.cc')
1166007Ssteve.reinhardt@amd.com        Source('pagetable_walker.cc')
1176007Ssteve.reinhardt@amd.com        Source('system.cc')
1186007Ssteve.reinhardt@amd.com        Source('stacktrace.cc')
1196007Ssteve.reinhardt@amd.com        Source('vtophys.cc')
1206007Ssteve.reinhardt@amd.com    else:
1216011Ssteve.reinhardt@amd.com        Source('process.cc')
1226007Ssteve.reinhardt@amd.com
1236007Ssteve.reinhardt@amd.com        Source('linux/linux.cc')
1246007Ssteve.reinhardt@amd.com        Source('linux/process.cc')
1256007Ssteve.reinhardt@amd.com        Source('linux/syscalls.cc')
1266007Ssteve.reinhardt@amd.com
1276008Ssteve.reinhardt@amd.com    python_files = (
1286007Ssteve.reinhardt@amd.com        '__init__.py',
1296008Ssteve.reinhardt@amd.com        'general_purpose/__init__.py',
1306008Ssteve.reinhardt@amd.com        'general_purpose/arithmetic/__init__.py',
1316008Ssteve.reinhardt@amd.com        'general_purpose/arithmetic/add_and_subtract.py',
1326008Ssteve.reinhardt@amd.com        'general_purpose/arithmetic/increment_and_decrement.py',
1336008Ssteve.reinhardt@amd.com        'general_purpose/arithmetic/multiply_and_divide.py',
1346008Ssteve.reinhardt@amd.com        'general_purpose/cache_and_memory_management.py',
1356008Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/__init__.py',
1366007Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/bit_scan.py',
1376007Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/bit_test.py',
1386007Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/bounds.py',
1396007Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/compare.py',
1406007Ssteve.reinhardt@amd.com        'general_purpose/compare_and_test/set_byte_on_condition.py',
1412929Sktlim@umich.edu        'general_purpose/compare_and_test/test.py',
1422929Sktlim@umich.edu        'general_purpose/control_transfer/__init__.py',
1432929Sktlim@umich.edu        'general_purpose/control_transfer/call.py',
1442929Sktlim@umich.edu        'general_purpose/control_transfer/conditional_jump.py',
1456007Ssteve.reinhardt@amd.com        'general_purpose/control_transfer/interrupts_and_exceptions.py',
1466007Ssteve.reinhardt@amd.com        'general_purpose/control_transfer/jump.py',
1472929Sktlim@umich.edu        'general_purpose/control_transfer/loop.py',
1482929Sktlim@umich.edu        'general_purpose/control_transfer/xreturn.py',
1492929Sktlim@umich.edu        'general_purpose/data_conversion/__init__.py',
1502929Sktlim@umich.edu        'general_purpose/data_conversion/ascii_adjust.py',
1516007Ssteve.reinhardt@amd.com        'general_purpose/data_conversion/bcd_adjust.py',
1526007Ssteve.reinhardt@amd.com        'general_purpose/data_conversion/endian_conversion.py',
1532929Sktlim@umich.edu        'general_purpose/data_conversion/extract_sign_mask.py',
1542929Sktlim@umich.edu        'general_purpose/data_conversion/sign_extension.py',
1556007Ssteve.reinhardt@amd.com        'general_purpose/data_conversion/translate.py',
1562929Sktlim@umich.edu        'general_purpose/data_transfer/__init__.py',
1572929Sktlim@umich.edu        'general_purpose/data_transfer/conditional_move.py',
1582929Sktlim@umich.edu        'general_purpose/data_transfer/move.py',
1592929Sktlim@umich.edu        'general_purpose/data_transfer/stack_operations.py',
1602929Sktlim@umich.edu        'general_purpose/data_transfer/xchg.py',
1612929Sktlim@umich.edu        'general_purpose/flags/__init__.py',
1622929Sktlim@umich.edu        'general_purpose/flags/load_and_store.py',
1634937Sstever@gmail.com        'general_purpose/flags/push_and_pop.py',
1644937Sstever@gmail.com        'general_purpose/flags/set_and_clear.py',
1654937Sstever@gmail.com        'general_purpose/input_output/__init__.py',
1664937Sstever@gmail.com        'general_purpose/input_output/general_io.py',
1674937Sstever@gmail.com        'general_purpose/input_output/string_io.py',
1684937Sstever@gmail.com        'general_purpose/load_effective_address.py',
1694937Sstever@gmail.com        'general_purpose/load_segment_registers.py',
1704937Sstever@gmail.com        'general_purpose/logical.py',
1714937Sstever@gmail.com        'general_purpose/no_operation.py',
1725773Snate@binkert.org        'general_purpose/processor_information.py',
1734937Sstever@gmail.com        'general_purpose/rotate_and_shift/__init__.py',
1744937Sstever@gmail.com        'general_purpose/rotate_and_shift/rotate.py',
1754937Sstever@gmail.com        'general_purpose/rotate_and_shift/shift.py',
1762929Sktlim@umich.edu        'general_purpose/semaphores.py',
1772929Sktlim@umich.edu        'general_purpose/string/__init__.py',
1782929Sktlim@umich.edu        'general_purpose/string/compare_strings.py',
1795773Snate@binkert.org        'general_purpose/string/load_string.py',
1802929Sktlim@umich.edu        'general_purpose/string/move_string.py',
1812929Sktlim@umich.edu        'general_purpose/string/scan_string.py',
1822929Sktlim@umich.edu        'general_purpose/string/store_string.py',
1832929Sktlim@umich.edu        'general_purpose/system_calls.py',
1842929Sktlim@umich.edu        'system/__init__.py',
1852929Sktlim@umich.edu        'system/halt.py',
1864937Sstever@gmail.com        'system/invlpg.py',
1874937Sstever@gmail.com        'system/undefined_operation.py',
1884937Sstever@gmail.com        'system/msrs.py',
1894937Sstever@gmail.com        'system/segmentation.py',
1904937Sstever@gmail.com        'simd128/__init__.py',
1914937Sstever@gmail.com        'simd128/integer/__init__.py',
1924937Sstever@gmail.com        'simd128/integer/data_transfer/__init__.py',
1934937Sstever@gmail.com        'simd128/integer/data_transfer/move.py',
1944937Sstever@gmail.com        'simd128/integer/data_transfer/move_non_temporal.py',
1954937Sstever@gmail.com        'simd128/integer/data_transfer/move_mask.py',
1964937Sstever@gmail.com        'simd128/integer/data_conversion/__init__.py',
1974937Sstever@gmail.com        'simd128/integer/data_conversion/convert_mmx_integer_to_floating_point.py',
1984937Sstever@gmail.com        'simd128/integer/data_conversion/convert_integer_to_floating_point.py',
1994937Sstever@gmail.com        'simd128/integer/data_conversion/convert_gpr_integer_to_floating_point.py',
2004937Sstever@gmail.com        'simd128/integer/data_reordering/__init__.py',
2012929Sktlim@umich.edu        'simd128/integer/data_reordering/unpack_and_interleave.py',
2022929Sktlim@umich.edu        'simd128/integer/data_reordering/pack_with_saturation.py',
2032929Sktlim@umich.edu        'simd128/integer/data_reordering/extract_and_insert.py',
2042929Sktlim@umich.edu        'simd128/integer/data_reordering/shuffle.py',
2052929Sktlim@umich.edu        'simd128/integer/arithmetic/__init__.py',
2062929Sktlim@umich.edu        'simd128/integer/arithmetic/subtraction.py',
2072929Sktlim@umich.edu        'simd128/integer/arithmetic/addition.py',
2086011Ssteve.reinhardt@amd.com        'simd128/integer/arithmetic/multiplication.py',
2092929Sktlim@umich.edu        'simd128/integer/arithmetic/multiply_add.py',
2102929Sktlim@umich.edu        'simd128/integer/arithmetic/average.py',
2112929Sktlim@umich.edu        'simd128/integer/arithmetic/sum_of_absolute_differences.py',
2122929Sktlim@umich.edu        'simd128/integer/shift/__init__.py',
2132929Sktlim@umich.edu        'simd128/integer/shift/right_arithmetic_shift.py',
2142929Sktlim@umich.edu        'simd128/integer/shift/left_logical_shift.py',
2152929Sktlim@umich.edu        'simd128/integer/shift/right_logical_shift.py',
2162929Sktlim@umich.edu        'simd128/integer/compare/__init__.py',
2172997Sstever@eecs.umich.edu        'simd128/integer/compare/compare_and_write_mask.py',
2182997Sstever@eecs.umich.edu        'simd128/integer/compare/compare_and_write_minimum_or_maximum.py',
2192929Sktlim@umich.edu        'simd128/integer/logical/__init__.py',
2202997Sstever@eecs.umich.edu        'simd128/integer/logical/pand.py',
2212997Sstever@eecs.umich.edu        'simd128/integer/logical/por.py',
2222929Sktlim@umich.edu        'simd128/integer/logical/exclusive_or.py',
2232997Sstever@eecs.umich.edu        'simd128/integer/save_and_restore_state/__init__.py',
2242997Sstever@eecs.umich.edu        'simd128/integer/save_and_restore_state/save_and_restore_state.py',
2252997Sstever@eecs.umich.edu        'simd128/integer/save_and_restore_state/save_and_restore_control_and_status.py',
2262929Sktlim@umich.edu        'simd128/floating_point/__init__.py',
2272997Sstever@eecs.umich.edu        'simd128/floating_point/data_transfer/__init__.py',
2282997Sstever@eecs.umich.edu        'simd128/floating_point/data_transfer/move_mask.py',
2292997Sstever@eecs.umich.edu        'simd128/floating_point/data_transfer/move.py',
2302997Sstever@eecs.umich.edu        'simd128/floating_point/data_transfer/move_with_duplication.py',
2315773Snate@binkert.org        'simd128/floating_point/data_transfer/move_non_temporal.py',
2325773Snate@binkert.org        'simd128/floating_point/data_conversion/__init__.py',
2332997Sstever@eecs.umich.edu        'simd128/floating_point/data_conversion/convert_floating_point_to_floating_point.py',
2342997Sstever@eecs.umich.edu        'simd128/floating_point/data_conversion/convert_floating_point_to_xmm_integer.py',
2356007Ssteve.reinhardt@amd.com        'simd128/floating_point/data_conversion/convert_floating_point_to_mmx_integer.py',
2366007Ssteve.reinhardt@amd.com        'simd128/floating_point/data_conversion/convert_floating_point_to_gpr_integer.py',
2372997Sstever@eecs.umich.edu        'simd128/floating_point/data_reordering/__init__.py',
2382929Sktlim@umich.edu        'simd128/floating_point/data_reordering/unpack_and_interleave.py',
2392997Sstever@eecs.umich.edu        'simd128/floating_point/data_reordering/shuffle.py',
2402997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/__init__.py',
2412997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/subtraction.py',
2422997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/addition.py',
2432997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/horizontal_subtraction.py',
2442997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/horizontal_addition.py',
2452997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/square_root.py',
2462929Sktlim@umich.edu        'simd128/floating_point/arithmetic/simultaneous_addition_and_subtraction.py',
2472997Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/multiplication.py',
2482929Sktlim@umich.edu        'simd128/floating_point/arithmetic/division.py',
2492929Sktlim@umich.edu        'simd128/floating_point/arithmetic/reciprocal_square_root.py',
2503005Sstever@eecs.umich.edu        'simd128/floating_point/arithmetic/reciprocal_estimation.py',
2513005Sstever@eecs.umich.edu        'simd128/floating_point/compare/__init__.py',
2523005Sstever@eecs.umich.edu        'simd128/floating_point/compare/compare_and_write_mask.py',
2533005Sstever@eecs.umich.edu        'simd128/floating_point/compare/compare_and_write_rflags.py',
2546025Snate@binkert.org        'simd128/floating_point/compare/compare_and_write_minimum_or_maximum.py',
2556025Snate@binkert.org        'simd128/floating_point/logical/__init__.py',
2566025Snate@binkert.org        'simd128/floating_point/logical/andp.py',
2576025Snate@binkert.org        'simd128/floating_point/logical/orp.py',
2586025Snate@binkert.org        'simd128/floating_point/logical/exclusive_or.py',
2596025Snate@binkert.org        'simd64/__init__.py',
2604130Ssaidi@eecs.umich.edu        'simd64/integer/__init__.py',
2614130Ssaidi@eecs.umich.edu        'simd64/integer/data_transfer/__init__.py',
2624130Ssaidi@eecs.umich.edu        'simd64/integer/data_transfer/move_mask.py',
2633691Shsul@eecs.umich.edu        'simd64/integer/data_transfer/move.py',
2643005Sstever@eecs.umich.edu        'simd64/integer/data_transfer/move_non_temporal.py',
2655721Shsul@eecs.umich.edu        'simd64/integer/exit_media_state.py',
2666194Sksewell@umich.edu        'simd64/integer/data_reordering/__init__.py',
2676194Sksewell@umich.edu        'simd64/integer/data_reordering/unpack_and_interleave.py',
2683005Sstever@eecs.umich.edu        'simd64/integer/data_reordering/pack_with_saturation.py',
2696168Snate@binkert.org        'simd64/integer/data_reordering/extract_and_insert.py',
2706168Snate@binkert.org        'simd64/integer/data_reordering/shuffle_and_swap.py',
2716168Snate@binkert.org        'simd64/integer/data_conversion.py',
2726166Ssteve.reinhardt@amd.com        'simd64/integer/arithmetic/__init__.py',
2732929Sktlim@umich.edu        'simd64/integer/arithmetic/subtraction.py',
2742929Sktlim@umich.edu        'simd64/integer/arithmetic/addition.py',
2753005Sstever@eecs.umich.edu        'simd64/integer/arithmetic/multiplication.py',
2762997Sstever@eecs.umich.edu        'simd64/integer/arithmetic/multiply_add.py',
2772997Sstever@eecs.umich.edu        'simd64/integer/arithmetic/average.py',
2786293Ssteve.reinhardt@amd.com        'simd64/integer/arithmetic/sum_of_absolute_differences.py',
2796293Ssteve.reinhardt@amd.com        'simd64/integer/shift/__init__.py',
2802929Sktlim@umich.edu        'simd64/integer/shift/right_arithmetic_shift.py',
281        'simd64/integer/shift/left_logical_shift.py',
282        'simd64/integer/shift/right_logical_shift.py',
283        'simd64/integer/compare/__init__.py',
284        'simd64/integer/compare/compare_and_write_mask.py',
285        'simd64/integer/compare/compare_and_write_minimum_or_maximum.py',
286        'simd64/integer/logical/__init__.py',
287        'simd64/integer/logical/pand.py',
288        'simd64/integer/logical/por.py',
289        'simd64/integer/logical/exclusive_or.py',
290        'simd64/integer/save_and_restore_state.py',
291        'simd64/floating_point/__init__.py',
292        'simd64/floating_point/arithmetic/__init__.py',
293        'simd64/floating_point/arithmetic/subtraction.py',
294        'simd64/floating_point/arithmetic/addition.py',
295        'simd64/floating_point/arithmetic/reciprocal_estimation.py',
296        'simd64/floating_point/arithmetic/multiplication.py',
297        'simd64/floating_point/arithmetic/accumulation.py',
298        'simd64/floating_point/arithmetic/reciprocal_square_root.py',
299        'simd64/floating_point/data_conversion.py',
300        'simd64/floating_point/compare/__init__.py',
301        'simd64/floating_point/compare/compare_and_write_mask.py',
302        'simd64/floating_point/compare/compare_and_write_minimum_or_maximum.py',
303        'x87/__init__.py',
304        'x87/data_transfer_and_conversion/__init__.py',
305        'x87/data_transfer_and_conversion/convert_and_load_or_store_integer.py',
306        'x87/data_transfer_and_conversion/load_or_store_floating_point.py',
307        'x87/data_transfer_and_conversion/exchange.py',
308        'x87/data_transfer_and_conversion/convert_and_load_or_store_bcd.py',
309        'x87/data_transfer_and_conversion/conditional_move.py',
310        'x87/data_transfer_and_conversion/extract.py',
311        'x87/load_constants/__init__.py',
312        'x87/load_constants/load_0_1_or_pi.py',
313        'x87/load_constants/load_logarithm.py',
314        'x87/arithmetic/__init__.py',
315        'x87/arithmetic/subtraction.py',
316        'x87/arithmetic/addition.py',
317        'x87/arithmetic/partial_remainder.py',
318        'x87/arithmetic/multiplication.py',
319        'x87/arithmetic/division.py',
320        'x87/arithmetic/change_sign.py',
321        'x87/arithmetic/round.py',
322        'x87/arithmetic/square_root.py',
323        'x87/transcendental_functions/__init__.py',
324        'x87/transcendental_functions/trigonometric_functions.py',
325        'x87/transcendental_functions/logarithmic_functions.py',
326        'x87/compare_and_test/__init__.py',
327        'x87/compare_and_test/classify.py',
328        'x87/compare_and_test/test.py',
329        'x87/compare_and_test/floating_point_ordered_compare.py',
330        'x87/compare_and_test/floating_point_unordered_compare.py',
331        'x87/compare_and_test/integer_compare.py',
332        'x87/stack_management/__init__.py',
333        'x87/stack_management/stack_control.py',
334        'x87/stack_management/clear_state.py',
335        'x87/control/__init__.py',
336        'x87/control/clear_exceptions.py',
337        'x87/control/initialize.py',
338        'x87/control/wait_for_exceptions.py',
339        'x87/control/save_x87_status_word.py',
340        'x87/control/save_and_restore_x87_control_word.py',
341        'x87/control/save_and_restore_x87_environment.py',
342        'x87/no_operation.py'
343        )
344
345
346    # Add in files generated by the ISA description.
347    isa_desc_files = env.ISADesc('isa/main.isa')
348    for f in isa_desc_files:
349        # Add in python file dependencies that won't be caught otherwise
350        for pyfile in python_files:
351            env.Depends(f, "isa/insts/%s" % pyfile)
352        # Only non-header files need to be compiled.
353        if not f.path.endswith('.hh'):
354            Source(f)
355
356    # Workaround for bug in SCons version > 0.97d20071212
357    # Scons bug id: 2006 M5 Bug id: 308
358    from os.path import dirname, join as joinpath
359
360    Dir('isa')
361    Dir('isa/microops')
362    Dir('isa/decoder')
363    Dir('isa/formats')
364    Dir('isa/insts')
365    isa_dirs = set(map(lambda x:dirname(x), python_files))
366    for d in isa_dirs:
367        Dir(joinpath('isa/insts', d))
368     
369