Home
last modified time | relevance | path

Searched full:magic (Results 1 – 25 of 5007) sorted by relevance

12345678910>>...201

/external/llvm-project/llvm/lib/BinaryFormat/
DMagic.cpp1 //===- llvm/BinaryFormat/Magic.cpp - File magic identification --*- C++ -*-===//
9 #include "llvm/BinaryFormat/Magic.h"
30 static bool startswith(StringRef Magic, const char (&S)[N]) { in startswith() argument
31 return Magic.startswith(StringRef(S, N - 1)); in startswith()
34 /// Identify the magic in magic.
35 file_magic llvm::identify_magic(StringRef Magic) { in identify_magic() argument
36 if (Magic.size() < 4) in identify_magic()
38 switch ((unsigned char)Magic[0]) { in identify_magic()
41 if (startswith(Magic, "\0\0\xFF\xFF")) { in identify_magic()
44 if (Magic.size() < MinSize) in identify_magic()
[all …]
/external/swiftshader/third_party/llvm-10.0/llvm/lib/BinaryFormat/
DMagic.cpp1 //===- llvm/BinaryFormat/Magic.cpp - File magic identification --*- C++ -*-===//
9 #include "llvm/BinaryFormat/Magic.h"
29 static bool startswith(StringRef Magic, const char (&S)[N]) { in startswith() argument
30 return Magic.startswith(StringRef(S, N - 1)); in startswith()
33 /// Identify the magic in magic.
34 file_magic llvm::identify_magic(StringRef Magic) { in identify_magic() argument
35 if (Magic.size() < 4) in identify_magic()
37 switch ((unsigned char)Magic[0]) { in identify_magic()
40 if (startswith(Magic, "\0\0\xFF\xFF")) { in identify_magic()
43 if (Magic.size() < MinSize) in identify_magic()
[all …]
/external/llvm-project/clang-tools-extra/test/clang-tidy/checkers/
Dreadability-magic-numbers.cpp1 // RUN: %check_clang_tidy %s readability-magic-numbers %t \
3 // RUN: [{key: readability-magic-numbers.IgnoredIntegerValues, value: "0;1;2;10;100;"}, \
4 // RUN: {key: readability-magic-numbers.IgnoredFloatingPointValues, value: "3.14;2.71828;9.81;100…
5 // RUN: {key: readability-magic-numbers.IgnoreBitFieldsWidths, value: 0}, \
6 // RUN: {key: readability-magic-numbers.IgnorePowersOf2IntegerValues, value: 1}]}' \
15 …GES: :[[@LINE-1]]:20: warning: 5 is a magic number; consider replacing it with a named constant [r…
23 …GES: :[[@LINE-1]]:21: warning: 6 is a magic number; consider replacing it with a named constant [r… in BuggyFunction()
26 …GES: :[[@LINE-1]]:20: warning: 7 is a magic number; consider replacing it with a named constant [r… in BuggyFunction()
29 …ES: :[[@LINE-1]]:18: warning: 15 is a magic number; consider replacing it with a named constant [r… in BuggyFunction()
32 …ES: :[[@LINE-1]]:25: warning: 22 is a magic number; consider replacing it with a named constant [r… in BuggyFunction()
[all …]
/external/ImageMagick/www/source/
Dmime.xml12 <!ATTLIST mime magic CDATA #IMPLIED>
22 …escription="Macintosh BinHex-encoded file" data-type="string" offset="11" magic="must be converted…
23 …ematica" description="Mathematica Notebook" data-type="string" offset="0" magic="(************** C…
24 …a" description="Mathematica Notebook" data-type="string" offset="100:256" magic="This notebook can…
25 …ca" description="Mathematica Notebook" data-type="string" offset="10:256" magic="This is a Mathema…
27 …<mime type="application/mbox" description="mailbox file" data-type="string" offset="0" magic="From…
30 …pdf" description="Portable Document Format" data-type="string" offset="0" magic="%PDF-" priority="…
32 …cription="XML Shareable Playlist Format" data-type="string" offset="0:64" magic="&lt;playlist vers…
34 …<mime type="audio/x-iriver-pla" description="iRiver Playlist" data-type="string" offset="4" magic=…
36 …ription="PGP/MIME-encrypted message header" data-type="string" offset="0" magic="-----BEGIN PGP ME…
[all …]
Dmagic.xml3 <!ELEMENT magicmap (magic)+>
4 <!ELEMENT magic (#PCDATA)>
5 <!ATTLIST magic name CDATA #REQUIRED>
6 <!ATTLIST magic offset CDATA "0">
7 <!ATTLIST magic target CDATA #REQUIRED>
19 <!-- <magic name="GIF" offset="0" target="GIF8"/> -->
20 <!-- <magic name="JPEG" offset="0" target="\377\330\377"/> -->
21 <!-- <magic name="PNG" offset="0" target="\211PNG\r\n\032\n"/> -->
22 <!-- <magic name="TIFF" offset="0" target="\115\115\000\052"/> -->
/external/ImageMagick/config/
Dmime.xml12 <!ATTLIST mime magic CDATA #IMPLIED>
22 …escription="Macintosh BinHex-encoded file" data-type="string" offset="11" magic="must be converted…
23 …ematica" description="Mathematica Notebook" data-type="string" offset="0" magic="(************** C…
24 …a" description="Mathematica Notebook" data-type="string" offset="100:256" magic="This notebook can…
25 …ca" description="Mathematica Notebook" data-type="string" offset="10:256" magic="This is a Mathema…
27 …<mime type="application/mbox" description="mailbox file" data-type="string" offset="0" magic="From…
30 …pdf" description="Portable Document Format" data-type="string" offset="0" magic="%PDF-" priority="…
32 …cription="XML Shareable Playlist Format" data-type="string" offset="0:64" magic="&lt;playlist vers…
34 …<mime type="audio/x-iriver-pla" description="iRiver Playlist" data-type="string" offset="4" magic=…
36 …ription="PGP/MIME-encrypted message header" data-type="string" offset="0" magic="-----BEGIN PGP ME…
[all …]
/external/e2fsprogs/lib/ext2fs/
Dext2_err.et.in15 "Wrong magic number for ext2_filsys structure"
18 "Wrong magic number for badblocks_list structure"
21 "Wrong magic number for badblocks_iterate structure"
24 "Wrong magic number for inode_scan structure"
27 "Wrong magic number for io_channel structure"
30 "Wrong magic number for unix io_channel structure"
33 "Wrong magic number for io_manager structure"
36 "Wrong magic number for block_bitmap structure"
39 "Wrong magic number for inode_bitmap structure"
42 "Wrong magic number for generic_bitmap structure"
[all …]
Dext2_err.c12 N_( "Wrong magic number for ext2_filsys structure"),
13 N_( "Wrong magic number for badblocks_list structure"),
14 N_( "Wrong magic number for badblocks_iterate structure"),
15 N_( "Wrong magic number for inode_scan structure"),
16 N_( "Wrong magic number for io_channel structure"),
17 N_( "Wrong magic number for unix io_channel structure"),
18 N_( "Wrong magic number for io_manager structure"),
19 N_( "Wrong magic number for block_bitmap structure"),
20 N_( "Wrong magic number for inode_bitmap structure"),
21 N_( "Wrong magic number for generic_bitmap structure"),
[all …]
Dgen_bitmap.c32 errcode_t magic; member
45 (((bmap)->magic == EXT2_ET_MAGIC_GENERIC_BITMAP) || \
46 ((bmap)->magic == EXT2_ET_MAGIC_BLOCK_BITMAP) || \
47 ((bmap)->magic == EXT2_ET_MAGIC_INODE_BITMAP))
50 (((bmap)->magic == EXT2_ET_MAGIC_GENERIC_BITMAP64) || \
51 ((bmap)->magic == EXT2_ET_MAGIC_BLOCK_BITMAP64) || \
52 ((bmap)->magic == EXT2_ET_MAGIC_INODE_BITMAP64))
74 if (!bitmap || !((bitmap->magic == EXT2_ET_MAGIC_GENERIC_BITMAP) || in check_magic()
75 (bitmap->magic == EXT2_ET_MAGIC_INODE_BITMAP) || in check_magic()
76 (bitmap->magic == EXT2_ET_MAGIC_BLOCK_BITMAP))) in check_magic()
[all …]
/external/llvm-project/llvm/test/Transforms/InstCombine/
Dconditional-variable-length-signext-after-high-bit-extract.ll23 ; CHECK-NEXT: [[MAGIC:%.*]] = select i1 [[SHOULD_SIGNEXT]], i32 [[ALL_BITS_EXCEPT_LOW_NBITS]], i…
28 ; CHECK-NEXT: call void @use32(i32 [[MAGIC]])
36 %magic = select i1 %should_signext, i32 %all_bits_except_low_nbits, i32 0
42 call void @use32(i32 %magic)
44 %signextended = add i32 %high_bits_extracted, %magic
54 ; CHECK-NEXT: [[MAGIC:%.*]] = select i1 [[SHOULD_SIGNEXT]], i32 [[ALL_BITS_EXCEPT_LOW_NBITS]], i…
59 ; CHECK-NEXT: call void @use32(i32 [[MAGIC]])
67 %magic = select i1 %should_signext, i32 %all_bits_except_low_nbits, i32 0
73 call void @use32(i32 %magic)
75 %signextended = or i32 %high_bits_extracted, %magic
[all …]
/external/igt-gpu-tools/tests/
Dcore_auth.c70 unsigned long magic, iocs; in check_auth() local
75 if (drmGetClient(fd, i, &auth, &pid, &uid, &magic, &iocs) != 0) in check_auth()
90 drm_magic_t magic, *magics = NULL; in test_many_magics() local
113 /* resize magic-map */ in test_many_magics()
130 /* insert magic */ in test_many_magics()
131 igt_assert(drmGetMagic(slave, &magic) == 0); in test_many_magics()
132 igt_assert(magic > 0); in test_many_magics()
134 magics[i] = magic; in test_many_magics()
142 * We cannot open the DRM file anymore. Lets sort the magic-map and in test_many_magics()
143 * verify no magic was used multiple times. in test_many_magics()
[all …]
/external/libdrm/
Dxf86drmSL.c58 unsigned long magic; /* SL_ENTRY_MAGIC */ member
66 unsigned long magic; /* SL_LIST_MAGIC */ member
82 entry->magic = SL_ENTRY_MAGIC; in SLCreateEntry()
108 list->magic = SL_LIST_MAGIC; in drmSLCreate()
124 if (list->magic != SL_LIST_MAGIC) return -1; /* Bad magic */ in drmSLDestroy()
127 if (entry->magic != SL_ENTRY_MAGIC) return -1; /* Bad magic */ in drmSLDestroy()
129 entry->magic = SL_FREED_MAGIC; in drmSLDestroy()
133 list->magic = SL_FREED_MAGIC; in drmSLDestroy()
144 if (list->magic != SL_LIST_MAGIC) return NULL; in SLLocate()
163 if (list->magic != SL_LIST_MAGIC) return -1; /* Bad magic */ in drmSLInsert()
[all …]
/external/llvm/lib/Support/
DPath.cpp981 /// @brief Identify the magic in magic.
982 file_magic identify_magic(StringRef Magic) { in identify_magic() argument
983 if (Magic.size() < 4) in identify_magic()
985 switch ((unsigned char)Magic[0]) { in identify_magic()
988 if (Magic[1] == (char)0x00 && Magic[2] == (char)0xff && in identify_magic()
989 Magic[3] == (char)0xff) { in identify_magic()
991 if (Magic.size() < MinSize) in identify_magic()
995 Magic.data() + offsetof(COFF::BigObjHeader, Version)); in identify_magic()
999 const char *Start = Magic.data() + offsetof(COFF::BigObjHeader, UUID); in identify_magic()
1006 if (Magic.size() >= sizeof(Expected) && in identify_magic()
[all …]
/external/python/cpython2/Tools/scripts/
Dfixheader.py3 # Add some standard cpp magic to a header file
29 magic = 'Py_'
32 magic = magic + c.upper()
33 else: magic = magic + '_'
35 print '#ifndef', magic
36 print '#define', magic
46 print '#endif /*', '!'+magic, '*/'
/external/python/cpython3/Tools/scripts/
Dfixheader.py3 # Add some standard cpp magic to a header file
30 magic = 'Py_'
33 magic = magic + c.upper()
34 else: magic = magic + '_'
35 print('#ifndef', magic, file=f)
36 print('#define', magic, file=f)
46 print('#endif /*', '!'+magic, '*/', file=f)
/external/linux-kselftest/tools/testing/selftests/arm64/signal/testcases/
Dtestcases.c5 struct _aarch64_ctx *get_header(struct _aarch64_ctx *head, uint32_t magic, in get_header() argument
15 head->magic != magic && head->magic) { in get_header()
19 if (head->magic == magic) { in get_header()
37 if (!term || term->magic || term->size) { in validate_extra_context()
71 switch (head->magic) { in validate_reserved()
109 * This is a BAD magic header defined in validate_reserved()
114 *err = "BAD MAGIC !"; in validate_reserved()
118 * A still unknown Magic: potentially freshly added in validate_reserved()
123 "SKIP Unknown MAGIC: 0x%X - Is KSFT arm64/signal up to date ?\n", in validate_reserved()
124 head->magic); in validate_reserved()
/external/swiftshader/third_party/llvm-subzero/lib/Support/
DPath.cpp984 static bool startswith(StringRef Magic, const char (&S)[N]) { in startswith() argument
985 return Magic.startswith(StringRef(S, N - 1)); in startswith()
988 /// @brief Identify the magic in magic.
989 file_magic identify_magic(StringRef Magic) { in identify_magic() argument
990 if (Magic.size() < 4) in identify_magic()
992 switch ((unsigned char)Magic[0]) { in identify_magic()
995 if (startswith(Magic, "\0\0\xFF\xFF")) { in identify_magic()
997 if (Magic.size() < MinSize) in identify_magic()
1000 const char *Start = Magic.data() + offsetof(COFF::BigObjHeader, UUID); in identify_magic()
1008 if (startswith(Magic, "\0\0\0\0\x20\0\0\0\xFF")) in identify_magic()
[all …]
/external/mesa3d/src/freedreno/common/
Dfreedreno_dev_info.c54 info->a6xx.magic.RB_UNKNOWN_8E04_blit = 0x00100000; in freedreno_dev_info_init()
55 info->a6xx.magic.PC_UNKNOWN_9805 = 0; in freedreno_dev_info_init()
56 info->a6xx.magic.SP_UNKNOWN_A0F8 = 0; in freedreno_dev_info_init()
63 info->a6xx.magic.RB_UNKNOWN_8E04_blit = 0x01000000; in freedreno_dev_info_init()
64 info->a6xx.magic.PC_UNKNOWN_9805 = 1; in freedreno_dev_info_init()
65 info->a6xx.magic.SP_UNKNOWN_A0F8 = 1; in freedreno_dev_info_init()
71 info->a6xx.magic.RB_UNKNOWN_8E04_blit = 0x00100000; in freedreno_dev_info_init()
72 info->a6xx.magic.PC_UNKNOWN_9805 = 1; in freedreno_dev_info_init()
73 info->a6xx.magic.SP_UNKNOWN_A0F8 = 1; in freedreno_dev_info_init()
79 info->a6xx.magic.RB_UNKNOWN_8E04_blit = 0x04100000; in freedreno_dev_info_init()
[all …]
/external/blktrace/
Dblktrace.h70 #define CHECK_MAGIC(t) (((t)->magic & 0xffffff00) == BLK_IO_TRACE_MAGIC)
98 fprintf(stderr, "bad trace magic %x\n", t->magic); in verify_trace()
101 if ((t->magic & 0xff) != SUPPORTED_VERSION) { in verify_trace()
103 t->magic & 0xff); in verify_trace()
115 t->magic = be32_to_cpu(t->magic); in trace_to_cpu()
131 static inline int check_data_endianness(u32 magic) in check_data_endianness() argument
133 if ((magic & 0xffffff00) == BLK_IO_TRACE_MAGIC) { in check_data_endianness()
138 magic = __bswap_32(magic); in check_data_endianness()
139 if ((magic & 0xffffff00) == BLK_IO_TRACE_MAGIC) { in check_data_endianness()
/external/dokka/core/testdata/format/website-html/
DoverloadGroup.html1 <div class='api-docs-breadcrumbs'><a href="index.html">test</a> / <a href="./magic.html">magic</a><…
2 <h1>magic</h1>
3 <div class="overload-group"><a name="$magic(kotlin.String)"></a>
4 …>fun </span><span class="identifier">magic</span><span class="symbol">(</span><span class="paramet…
10 <div class="overload-group"><a name="$magic(kotlin.Int)"></a>
11 …>fun </span><span class="identifier">magic</span><span class="symbol">(</span><span class="paramet…
/external/mesa3d/src/util/
Du_debug_memory.c78 unsigned magic; member
84 unsigned magic; member
143 hdr->magic = DEBUG_MEMORY_MAGIC; in debug_malloc()
154 ftr->magic = DEBUG_MEMORY_MAGIC; in debug_malloc()
174 if (hdr->magic != DEBUG_MEMORY_MAGIC) { in debug_free()
183 if (ftr->magic != DEBUG_MEMORY_MAGIC) { in debug_free()
204 hdr->magic = 0; in debug_free()
205 ftr->magic = 0; in debug_free()
238 if (old_hdr->magic != DEBUG_MEMORY_MAGIC) { in debug_realloc()
247 if (old_ftr->magic != DEBUG_MEMORY_MAGIC) { in debug_realloc()
[all …]
/external/oss-fuzz/projects/file/
Dmagic_fuzzer.cc22 #include <magic.h>
26 magic = magic_open(MAGIC_NONE); in Environment()
27 std::string magic_path = data_dir + "/magic"; in Environment()
28 if (magic_load(magic, magic_path.c_str())) { in Environment()
29 fprintf(stderr, "error loading magic file: %s\n", magic_error(magic)); in Environment()
34 magic_t magic; member
52 magic_buffer(env->magic, data, size); in LLVMFuzzerTestOneInput()
/external/llvm-project/llvm/unittests/BinaryFormat/
DTestFileMagic.cpp1 //===- llvm/unittest/BinaryFormat/TestFileMagic.cpp - File magic tests ----===//
11 #include "llvm/BinaryFormat/Magic.h"
88 TEST_F(MagicTest, Magic) { in TEST_F() argument
93 file_magic magic; in TEST_F() member
95 #define DEFINE(magic) {#magic, magic, sizeof(magic), file_magic::magic} in TEST_F() argument
125 // Create some files filled with magic. in TEST_F()
133 StringRef magic(i->magic_str, i->magic_str_len); in TEST_F() local
134 file << magic; in TEST_F()
136 EXPECT_EQ(i->magic, identify_magic(magic)); in TEST_F()
/external/swiftshader/third_party/llvm-10.0/llvm/lib/ExecutionEngine/JITLink/
DMachO.cpp41 uint32_t Magic; in jitLink_MachO() local
42 memcpy(&Magic, Data.data(), sizeof(uint32_t)); in jitLink_MachO()
44 dbgs() << "jitLink_MachO: magic = " << format("0x%08" PRIx32, Magic) in jitLink_MachO()
49 if (Magic == MachO::MH_MAGIC || Magic == MachO::MH_CIGAM) { in jitLink_MachO()
53 } else if (Magic == MachO::MH_MAGIC_64 || Magic == MachO::MH_CIGAM_64) { in jitLink_MachO()
57 if (Magic == MachO::MH_CIGAM_64) in jitLink_MachO()
77 Ctx->notifyFailed(make_error<JITLinkError>("MachO magic not valid")); in jitLink_MachO()
/external/pigweed/pw_kvs/public/pw_kvs/
Dformat.h30 // For KVS magic value always use a random 32 bit integer rather than a
33 uint32_t magic; member
71 bool KnownMagic(uint32_t magic) const { return Find(magic) != nullptr; } in KnownMagic() argument
73 const EntryFormat* Find(uint32_t magic) const;
81 // The EntryFormat defines properties of KVS entries that use a particular magic
84 // Magic is a unique constant identifier for entries.
86 // Upon reading from an address in flash, the magic number facilitiates
93 // When selecting a magic for your particular KVS, pick a random 32 bit
101 uint32_t magic; member

12345678910>>...201