Применение искинов - шоссе империализма (Стенгазета русификаторов ИТ)

Информация о пользователе

Привет, Гость! Войдите или зарегистрируйтесь.


Вы здесь » Применение искинов - шоссе империализма (Стенгазета русификаторов ИТ) » Интел64 » Опкоды интел в машиночитаемом формате - где?


Опкоды интел в машиночитаемом формате - где?

Сообщений 1 страница 7 из 7

1

1) http://ref.x86asm.net/x86reference.xml
http://ref.x86asm.net/index.html
http://ref.x86asm.net/coder64.html
«Its principal aim is exact definition of instruction parameters and attributes.»
«primary source of this reference is an XML document»

2) https://www.felixcloutier.com/x86/
https://github.com/fay59/x86doc
Утилита, которая парсит руководство Интел и создаёт HTML-файлы.

Есть для x86 (старой):
https://en.wikipedia.org/wiki/X86_instruction_listings

обзорные:
https://en.wikipedia.org/wiki/X86-64
https://en.wikibooks.org/wiki/X86_Disas … ecompilers

Отредактировано Лис (2023-03-17 04:15:57)

0

2

Наверное было бы логично посмотреть, как там устроена утилита objdump.
Вдруг она написана на Си?
$ git clone git://sourceware.org/git/binutils-gdb.git
Cloning into 'binutils-gdb'...
remote: Enumerating objects: 45389, done.
remote: Counting objects: 100% (45389/45389), done.
remote: Compressing objects: 100% (41392/41392), done.
remote: Total 1165923 (delta 8421), reused 5036 (delta 3968), pack-reused 1120534
Receiving objects: 100% (1165923/1165923), 428.98 MiB | 5.25 MiB/s, done.
Resolving deltas: 100% (966734/966734), done.
Updating files: 100% (38376/38376), done.

$ find . -iname objdump.c
./binutils/objdump.c

«The actual disassembling is done by the libopcodes library, via a function pointer supplied by the disassembler() function.»

opcodes $ ls -i | grep i386
i386-dis.c
i386-dis-evex.h
i386-dis-evex-len.h
i386-dis-evex-mod.h
i386-dis-evex-prefix.h
i386-dis-evex-reg.h
i386-dis-evex-w.h
i386-gen.c
i386-init.h
i386-mnem.h
i386-opc.h
i386-opc.tbl
i386-reg.tbl
i386-tbl.h

«x86-64 support added by Jan Hubicka (jh@suse.cz)»
(один человек справился)

Отредактировано Лис (2023-03-17 04:43:26)

0

3

Если есть в природе процессоры этой архитектуры (и они временно доступны россиянам),
то временно имеет смысл уметь расшифровывать их коды в кириллицу. Логично?

Переводить и кириллизировать это не надо, а вот прочитать и понять, чтобы подумать как сделать лучше - это возможно.

i386-dis.c

Как почувствовать себя уникальным специалистом? Несмотря на то, что это опенсорс, уверен, что людей вдумчиво читавших этот файл меньше чем космонавтов.

Отредактировано Лис (2023-03-17 04:41:51)

0

4

https://github.com/zyantific/zydis
«Fast and lightweight x86/x86-64 disassembler and code generation library»
Си - 99.1%
MIT license.

«bindings exist for Pyhton3, Haskell, Rust»
(у меня тоже была подобная идея - GObject Introspection )

Отредактировано Лис (2023-03-17 04:52:20)

0

5

То есть, несмотря на то, что у них единый язык, они всё равно запрограммировали это несколько раз (минимум четырежды - в руководстве, в XML-файле и в минимум двух утилитах). Почему нельзя нам?

Отредактировано Лис (2023-03-17 05:09:30)

0

6

см. также
2012, Ulan Degenbaev, Formal Specification of the x86 ISA
1997, Ramsey, Specifying Representations of Machine Instructions

Отредактировано Лис (2024-08-24 04:41:55)

0

7

Из работы 2017-06-08, Dasgupta, A Complete Formal Semantics of x86-64

«Existing Semantics for x86-64 To date, to the best of our knowledge, despite several explicit attempts [32, 33, 37] and other related systems [13, 35, 36, 41, 42], no complete formal semantics of x86-64 exists that can be used for formal reasoning about x86 binary programs. Heule et al. [37] presented a formal semantics of x86-64, but it covers only a fragment (∼47%) of all instructions; as the authors of [37] candidly admitted, their synthesis methodology proved insufficient to add the remaining instructions primarily due to limitations of the underlying synthesis engine. Moreover, their semantics misses certain essential details (Section 3.6 & 4).
Goel et al. [32, 33], on the other hand, specified a formal semantics in the ACL2 proof assistant [38], allowing to reason about functional correctness, but their semantics covers only a small fragment (∼33%) of all user-level instructions.
There also have been several attempts [20, 24, 35, 60] to indirectly describe the x86-64 semantics, where they define an intermediate language (IL), specify the IL semantics, and translate x86-64 to the IL. This indirect semantics, however, may not be general enough to be used for different types of formal analyses, since the IL might be designed with specific purposes in mind, not to mention that the translation may miss certain important details of the instruction behaviors.
Refer to Section 7 for a more detailed comparison to existing semantics.»

Отредактировано Лис (2024-08-24 04:40:43)

0


Вы здесь » Применение искинов - шоссе империализма (Стенгазета русификаторов ИТ) » Интел64 » Опкоды интел в машиночитаемом формате - где?