Home
last modified time | relevance | path

Searched refs:beg (Results 1 – 25 of 110) sorted by relevance

12345

/freebsd-13-stable/contrib/nvi/vi/
HDv_increment.c54 size_t beg, blen, end, len, nlen, wlen; in v_increment() local
89 for (beg = vp->m_start.cno; beg < len && ISSPACE(p[beg]); ++beg); in v_increment()
90 if (beg >= len) in v_increment()
92 if (beg != vp->m_start.cno) { in v_increment()
93 sp->cno = beg; in v_increment()
108 wlen = len - beg; in v_increment()
109 if (p[beg] == '0' && wlen > 2 && in v_increment()
110 (p[beg + 1] == 'X' || p[beg + 1] == 'x')) { in v_increment()
112 end = beg + 2; in v_increment()
115 ntype = p[beg + 1] == 'X' ? fmt[HEXC] : fmt[HEXL]; in v_increment()
[all …]
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/asan/
HDasan_poisoning.cpp109 ShadowSegmentEndpoint beg(beg_addr); in __asan_poison_memory_region() local
111 if (beg.chunk == end.chunk) { in __asan_poison_memory_region()
112 CHECK_LT(beg.offset, end.offset); in __asan_poison_memory_region()
113 s8 value = beg.value; in __asan_poison_memory_region()
118 if (beg.offset > 0) { in __asan_poison_memory_region()
119 *beg.chunk = Min(value, beg.offset); in __asan_poison_memory_region()
121 *beg.chunk = kAsanUserPoisonedMemoryMagic; in __asan_poison_memory_region()
126 CHECK_LT(beg.chunk, end.chunk); in __asan_poison_memory_region()
127 if (beg.offset > 0) { in __asan_poison_memory_region()
129 if (beg.value == 0) { in __asan_poison_memory_region()
[all …]
HDasan_globals.cpp59 FastPoisonShadow(g->beg, g->size_with_redzone, value); in PoisonShadowForGlobal()
64 FastPoisonShadow(g.beg + aligned_size, g.size_with_redzone - aligned_size, in PoisonRedZones()
68 g.beg + RoundDownTo(g.size, ASAN_SHADOW_GRANULARITY), in PoisonRedZones()
77 if (addr <= g.beg - kMinimalDistanceFromAnotherGlobal) return false; in IsAddressNearGlobal()
78 if (addr >= g.beg + g.size_with_redzone) return false; in IsAddressNearGlobal()
84 bool symbolized = Symbolizer::GetOrInit()->SymbolizeData(g.beg, &info); in ReportGlobal()
89 prefix, (void *)&g, (void *)g.beg, g.size, g.size_with_redzone, g.name, in ReportGlobal()
165 if (__asan_region_is_poisoned(g->beg, g->size_with_redzone)) { in CheckODRViolationViaPoisoning()
169 if (g->beg == l->g->beg && in CheckODRViolationViaPoisoning()
206 CHECK(AddrIsInMem(g->beg)); in RegisterGlobal()
[all …]
HDasan_descriptions.cpp226 uptr var_end = var.beg + var.size; in PrintAccessAndVarIntersection()
231 if (addr >= var.beg) { in PrintAccessAndVarIntersection()
240 if (addr_end > var.beg) in PrintAccessAndVarIntersection()
242 else if (addr >= prev_var_end && addr - prev_var_end >= var.beg - addr_end) in PrintAccessAndVarIntersection()
246 str.AppendF(" [%zd, %zd)", var.beg, var_end); in PrintAccessAndVarIntersection()
281 if (addr < g.beg) { in DescribeAddressRelativeToGlobal()
282 str.AppendF("%p is located %zd bytes before", (void *)addr, g.beg - addr); in DescribeAddressRelativeToGlobal()
283 } else if (addr + access_size > g.beg + g.size) { in DescribeAddressRelativeToGlobal()
284 if (addr < g.beg + g.size) addr = g.beg + g.size; in DescribeAddressRelativeToGlobal()
286 addr - (g.beg + g.size)); in DescribeAddressRelativeToGlobal()
[all …]
HDasan_fake_stack.cpp118 uptr beg = reinterpret_cast<uptr>(GetFrame(stack_size_log, 0, 0)); in AddrIsInFakeStack() local
120 if (ptr < beg || ptr >= end) return 0; in AddrIsInFakeStack()
121 uptr class_id = (ptr - beg) >> stack_size_log; in AddrIsInFakeStack()
122 uptr base = beg + (class_id << stack_size_log); in AddrIsInFakeStack()
293 void *__asan_addr_is_in_fake_stack(void *fake_stack, void *addr, void **beg, in __asan_addr_is_in_fake_stack() argument
303 if (beg) *beg = reinterpret_cast<void*>(frame_beg); in __asan_addr_is_in_fake_stack()
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/msan/
HDmsan_poisoning.cpp48 uptr beg = d & ~3UL; in CopyOrigin() local
50 if (beg < d) { in CopyOrigin()
51 u32 o = GetOriginIfPoisoned((uptr)src, beg + 4 - d); in CopyOrigin()
54 *(u32 *)MEM_TO_ORIGIN(beg) = o; in CopyOrigin()
56 beg += 4; in CopyOrigin()
61 if (end < beg) return; in CopyOrigin()
72 if (beg < end) { in CopyOrigin()
79 u32 *src_end = (u32 *)MEM_TO_ORIGIN(s + (end - beg)); in CopyOrigin()
80 u32 *dst = (u32 *)MEM_TO_ORIGIN(beg); in CopyOrigin()
92 REAL(memcpy)((void *)MEM_TO_ORIGIN(beg), (void *)MEM_TO_ORIGIN(s), in CopyOrigin()
[all …]
HDmsan_linux.cpp42 void ReportMapRange(const char *descr, uptr beg, uptr size) { in ReportMapRange() argument
44 uptr end = beg + size - 1; in ReportMapRange()
45 VPrintf(1, "%s : %p-%p\n", descr, (void *)beg, (void *)end); in ReportMapRange()
49 static bool CheckMemoryRangeAvailability(uptr beg, uptr size, bool verbose) { in CheckMemoryRangeAvailability() argument
51 uptr end = beg + size - 1; in CheckMemoryRangeAvailability()
52 if (!MemoryRangeIsAvailable(beg, end)) { in CheckMemoryRangeAvailability()
55 (void *)beg, (void *)end); in CheckMemoryRangeAvailability()
62 static bool ProtectMemoryRange(uptr beg, uptr size, const char *name) { in ProtectMemoryRange() argument
64 void *addr = MmapFixedNoAccess(beg, size, name); in ProtectMemoryRange()
65 if (beg == 0 && addr) { in ProtectMemoryRange()
[all …]
/freebsd-13-stable/contrib/ncurses/ncurses/base/
HDlib_redrawln.c46 wredrawln(WINDOW *win, int beg, int num) in NCURSES_EXPORT()
53 T((T_CALLED("wredrawln(%p,%d,%d)"), (void *) win, beg, num)); in NCURSES_EXPORT()
60 if (beg < 0) in NCURSES_EXPORT()
61 beg = 0; in NCURSES_EXPORT()
63 if (touchline(win, beg, num) == ERR) in NCURSES_EXPORT()
66 if (touchline(CurScreen(sp), beg + win->_begy, num) == ERR) in NCURSES_EXPORT()
69 end = beg + num; in NCURSES_EXPORT()
80 for (i = beg; i < end; i++) { in NCURSES_EXPORT()
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/tsan/rtl/
HDtsan_platform_posix.cpp82 static bool TryProtectRange(uptr beg, uptr end) { in TryProtectRange() argument
83 CHECK_LE(beg, end); in TryProtectRange()
84 if (beg == end) in TryProtectRange()
86 return beg == (uptr)MmapFixedNoAccess(beg, end - beg); in TryProtectRange()
89 static void ProtectRange(uptr beg, uptr end) { in ProtectRange() argument
90 if (!TryProtectRange(beg, end)) { in ProtectRange()
91 Printf("FATAL: ThreadSanitizer can not protect [%zx,%zx]\n", beg, end); in ProtectRange()
/freebsd-13-stable/crypto/heimdal/appl/push/
HDpush.c315 char *beg, *p; in doit() local
336 beg = in_buf; in doit()
339 && (p = strstr(beg, "\r\n")) != NULL) { in doit()
341 char *copy = beg; in doit()
351 if (beg[0] == '.' && beg[1] == '\r' && beg[2] == '\n') { in doit()
362 rem -= p - beg + 2; in doit()
363 beg = p + 2; in doit()
365 char *copy = beg; in doit()
366 if (beg[0] == '.') { in doit()
367 if (beg[1] == '\r' && beg[2] == '\n') { in doit()
[all …]
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/dfsan/
HDdfsan.cpp250 uptr beg = OriginAlignDown(d); in CopyOrigin() local
252 if (beg < d) { in CopyOrigin()
253 ChainAndWriteOriginIfTainted((uptr)src, beg + kOriginAlign - d, beg, stack); in CopyOrigin()
254 beg += kOriginAlign; in CopyOrigin()
259 if (end < beg) in CopyOrigin()
267 if (beg >= end) in CopyOrigin()
274 dfsan_origin *src_end = origin_for((void *)(src_a + (end - beg))); in CopyOrigin()
275 dfsan_origin *dst_o = origin_for((void *)beg); in CopyOrigin()
302 uptr beg = OriginAlignDown(d); in ReverseCopyOrigin() local
304 if (beg + kOriginAlign < end) { in ReverseCopyOrigin()
[all …]
/freebsd-13-stable/lib/libc/gen/
HDtimezone.c56 char *beg, in timezone() local
59 if ( (beg = getenv("TZNAME")) ) { /* set in environment */ in timezone()
60 if ((end = strchr(beg, ','))) { /* "PST,PDT" */ in timezone()
64 (void)strncpy(czone,beg,sizeof(czone) - 1); in timezone()
69 return(beg); in timezone()
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/sanitizer_common/
HDsanitizer_common_libcdep.cpp162 void ReserveShadowMemoryRange(uptr beg, uptr end, const char *name, in ReserveShadowMemoryRange() argument
164 CHECK_EQ((beg % GetMmapGranularity()), 0); in ReserveShadowMemoryRange()
166 uptr size = end - beg + 1; in ReserveShadowMemoryRange()
168 if (madvise_shadow ? !MmapFixedSuperNoReserve(beg, size, name) in ReserveShadowMemoryRange()
169 : !MmapFixedNoReserve(beg, size, name)) { in ReserveShadowMemoryRange()
177 DontDumpShadowMemory(beg, size); in ReserveShadowMemoryRange()
HDsanitizer_allocator_secondary.h230 uptr beg = 0, end = n - 1; in GetBlockBeginFastLocked() local
233 while (end - beg >= 2) { in GetBlockBeginFastLocked()
234 uptr mid = (beg + end) / 2; // Invariant: mid >= beg + 1 in GetBlockBeginFastLocked()
238 beg = mid; // chunks[mid] may still be what we want. in GetBlockBeginFastLocked()
241 if (beg < end) { in GetBlockBeginFastLocked()
242 CHECK_EQ(beg + 1, end); in GetBlockBeginFastLocked()
245 beg = end; in GetBlockBeginFastLocked()
248 const Header *h = AddressSpaceView::Load(chunks[beg]); in GetBlockBeginFastLocked()
249 Header *h_ptr = chunks[beg]; in GetBlockBeginFastLocked()
HDsanitizer_allocator_primary64.h266 uptr beg = chunk_idx * size; in GetBlockBegin() local
267 uptr next_beg = beg + size; in GetBlockBegin()
270 return reinterpret_cast<void*>(reg_beg + beg); in GetBlockBegin()
711 bool MapWithCallback(uptr beg, uptr size, const char *name) { in MapWithCallback() argument
713 return beg >= NonConstSpaceBeg && in MapWithCallback()
714 beg + size <= NonConstSpaceBeg + kSpaceSize; in MapWithCallback()
715 uptr mapped = address_range.Map(beg, size, name); in MapWithCallback()
718 CHECK_EQ(beg, mapped); in MapWithCallback()
719 MapUnmapCallback().OnMap(beg, size); in MapWithCallback()
723 void MapWithCallbackOrDie(uptr beg, uptr size, const char *name) { in MapWithCallbackOrDie() argument
[all …]
HDsanitizer_allocator_primary32.h146 void UnmapWithCallback(uptr beg, uptr size) { in UnmapWithCallback() argument
147 MapUnmapCallback().OnUnmap(beg, size); in UnmapWithCallback()
148 UnmapOrDie(reinterpret_cast<void *>(beg), size); in UnmapWithCallback()
160 uptr beg = ComputeRegionBeg(mem); in GetMetaData() local
162 u32 offset = mem - beg; in GetMetaData()
164 uptr meta = (beg + kRegionSize) - (n + 1) * kMetadataSize; in GetMetaData()
209 uptr beg = ComputeRegionBeg(mem); in GetBlockBegin() local
211 u32 offset = mem - beg; in GetBlockBegin()
213 uptr res = beg + (n * (u32)size); in GetBlockBegin()
HDsanitizer_coverage_libcdep_new.cpp192 static void Cov8bitCountersInit(char* beg, char* end) { in Cov8bitCountersInit() argument
193 counters_beg = beg; in Cov8bitCountersInit()
198 static void CovPcsInit(const uptr* beg, const uptr* end) { in CovPcsInit() argument
199 pcs_beg = beg; in CovPcsInit()
278 SANITIZER_INTERFACE_WEAK_DEF(void, __sanitizer_cov_pcs_init, const uptr* beg, in SANITIZER_INTERFACE_WEAK_DEF() argument
280 __sancov::SingletonCounterCoverage::CovPcsInit(beg, end); in SANITIZER_INTERFACE_WEAK_DEF()
HDsanitizer_libignore.cpp84 ignored_code_ranges_[idx].begin = range.beg; in OnLibraryLoaded()
106 if (IsPcInstrumented(range.beg) && IsPcInstrumented(range.end - 1)) in OnLibraryLoaded()
109 (void *)range.beg, (void *)range.end, mod.full_name()); in OnLibraryLoaded()
113 instrumented_code_ranges_[idx].begin = range.beg; in OnLibraryLoaded()
/freebsd-13-stable/usr.bin/mail/
HDlist.c118 int tok, beg, mc, star, other, valdot, colmod, colresult; in markall() local
131 beg = 0; in markall()
142 if (beg != 0) { in markall()
145 for (i = beg; i <= lexnumber; i++) in markall()
148 beg = 0; in markall()
151 beg = lexnumber; in markall()
152 if (check(beg, f)) in markall()
157 mark(beg); in markall()
158 beg = 0; in markall()
163 if (beg != 0) { in markall()
[all …]
/freebsd-13-stable/sys/dev/netmap/
HDnetmap_monitor.c593 u_int beg, end, i; in netmap_zmon_parent_sync() local
607 beg = kring->nr_hwtail + 1; in netmap_zmon_parent_sync()
613 beg = kring->nr_hwcur; in netmap_zmon_parent_sync()
617 rel_slots = end - beg; in netmap_zmon_parent_sync()
645 beg += (rel_slots - free_slots); in netmap_zmon_parent_sync()
648 if (unlikely(beg >= kring->nkr_num_slots)) in netmap_zmon_parent_sync()
649 beg -= kring->nkr_num_slots; in netmap_zmon_parent_sync()
653 struct netmap_slot *s = &ring->slot[beg]; in netmap_zmon_parent_sync()
660 nm_prdis(5, "beg %d buf_idx %d", beg, tmp); in netmap_zmon_parent_sync()
669 beg = nm_next(beg, lim); in netmap_zmon_parent_sync()
[all …]
/freebsd-13-stable/contrib/llvm-project/compiler-rt/lib/hwasan/
HDhwasan_interceptors.cpp200 uptr beg = reinterpret_cast<uptr>(res); in mmap_interceptor() local
201 DCHECK(IsAligned(beg, GetPageSize())); in mmap_interceptor()
202 if (!MemIsApp(beg) || !MemIsApp(beg + rounded_length - 1)) { in mmap_interceptor()
209 __hwasan::TagMemoryAligned(beg, rounded_length, 0); in mmap_interceptor()
219 uptr beg = reinterpret_cast<uptr>(addr); in munmap_interceptor() local
220 if (length && IsAligned(beg, GetPageSize())) { in munmap_interceptor()
223 if (!MemIsApp(beg) || !MemIsApp(beg + rounded_length - 1)) { in munmap_interceptor()
227 __hwasan::TagMemoryAligned(beg, rounded_length, 0); in munmap_interceptor()
/freebsd-13-stable/usr.sbin/pmcstudy/
HDeval_expr.c208 walk_back_and_insert_paren(struct expression **beg, struct expression *frm) in walk_back_and_insert_paren() argument
222 if (at == *beg) { in walk_back_and_insert_paren()
227 *beg = ex; in walk_back_and_insert_paren()
254 if (at == *beg) { in walk_back_and_insert_paren()
315 add_precendence(struct expression **beg, struct expression *start, struct expression *end) in add_precendence() argument
338 walk_back_and_insert_paren(beg, at); in add_precendence()
350 set_math_precidence(struct expression **beg, struct expression *exp, struct expression **stopped) in set_math_precidence() argument
369 add_precendence(beg, start, end); in set_math_precidence()
374 set_math_precidence(beg, at->next, &end); in set_math_precidence()
387 add_precendence(beg, start, NULL); in set_math_precidence()
/freebsd-13-stable/usr.bin/split/
HDsplit.c365 char beg, end; in newfile() local
384 beg = '0'; in newfile()
388 beg = 'a'; in newfile()
391 pattlen = end - beg + 1; in newfile()
411 fpnt[1] = beg; in newfile()
439 fpnt[i] = tfnum % pattlen + beg; in newfile()
/freebsd-13-stable/contrib/llvm-project/lldb/source/Plugins/SymbolFile/DWARF/
HDDWARFAttribute.cpp22 collection::const_iterator beg = m_infos.begin(); in FindAttributeIndex() local
24 for (pos = beg; pos != end; ++pos) { in FindAttributeIndex()
26 return std::distance(beg, pos); in FindAttributeIndex()
/freebsd-13-stable/lib/libfetch/
HDftp.c272 const char *beg, *end; in ftp_cwd() local
308 for (beg = file + i; beg < end && *beg == '/'; ++beg, ++i) in ftp_cwd()
312 if (beg >= end) in ftp_cwd()
316 e = ftp_cmd(conn, "CWD %.*s", (int)(end - beg), beg); in ftp_cwd()
322 for (beg = file + i; beg < end; beg = file + i + 1) { in ftp_cwd()
323 while (*beg == '/') in ftp_cwd()
324 ++beg, ++i; in ftp_cwd()
327 e = ftp_cmd(conn, "CWD %.*s", file + i - beg, beg); in ftp_cwd()

12345