Home
last modified time | relevance | path

Searched full:hook (Results 1 – 25 of 2956) sorted by relevance

12345678910>>...119

/external/linux-kselftest/tools/testing/selftests/bpf/prog_tests/
Dtc_bpf.c25 static int test_tc_bpf_basic(const struct bpf_tc_hook *hook, int fd) in test_tc_bpf_basic() argument
36 ret = bpf_tc_attach(hook, &opts); in test_tc_bpf_basic()
47 ret = bpf_tc_attach(hook, &opts); in test_tc_bpf_basic()
52 ret = bpf_tc_query(hook, &opts); in test_tc_bpf_basic()
63 ret = bpf_tc_detach(hook, &opts); in test_tc_bpf_basic()
68 static int test_tc_bpf_api(struct bpf_tc_hook *hook, int fd) in test_tc_bpf_api() argument
76 if (!ASSERT_EQ(ret, -EINVAL, "bpf_tc_hook_create invalid hook = NULL")) in test_tc_bpf_api()
79 /* hook ifindex = 0 */ in test_tc_bpf_api()
81 if (!ASSERT_EQ(ret, -EINVAL, "bpf_tc_hook_create invalid hook ifindex == 0")) in test_tc_bpf_api()
85 if (!ASSERT_EQ(ret, -EINVAL, "bpf_tc_hook_destroy invalid hook ifindex == 0")) in test_tc_bpf_api()
[all …]
/external/trace-cmd/lib/trace-cmd/
Dtrace-hooks.c17 struct hook_list *hook; in tracecmd_create_event_hook() local
29 hook = malloc(sizeof(*hook)); in tracecmd_create_event_hook()
30 if (!hook) in tracecmd_create_event_hook()
32 memset(hook, 0, sizeof(*hook)); in tracecmd_create_event_hook()
36 free(hook); in tracecmd_create_event_hook()
40 hook->str = str; in tracecmd_create_event_hook()
41 hook->hook = arg; in tracecmd_create_event_hook()
83 hook->start_system = system; in tracecmd_create_event_hook()
84 hook->start_event = event; in tracecmd_create_event_hook()
85 hook->start_match = match; in tracecmd_create_event_hook()
[all …]
/external/python/cpython3/Lib/test/
Daudit-tests.py14 """Used in standard hook tests to collect any logged events.
83 with TestHook() as hook:
85 assertEqual(hook.seen[0][0], "test_event")
86 assertEqual(hook.seen[0][1], (1, 2, 3))
90 # Raising an exception should prevent a new hook from being added,
100 # Raising BaseException will propagate out when adding a hook
105 # Adding this next hook should raise BaseException
115 with TestHook() as hook:
126 actual = [(a[0], a[1]) for e, a in hook.seen if e == "marshal.dumps"]
129 actual = [a[0] for e, a in hook.seen if e == "marshal.loads"]
[all …]
/external/tensorflow/tensorflow/python/training/
Dbasic_session_run_hooks_test.py246 hook = basic_session_run_hooks.LoggingTensorHook(
248 hook.begin()
249 mon_sess = monitored_session._HookedSession(sess, [hook])
257 hook.end(sess)
264 hook = basic_session_run_hooks.LoggingTensorHook(
266 hook.begin()
267 mon_sess = monitored_session._HookedSession(sess, [hook])
287 hook.end(sess)
311 hook = basic_session_run_hooks.LoggingTensorHook(
313 hook.begin()
[all …]
/external/pigweed/pw_presubmit/py/pw_presubmit/
Dinstall_hook.py15 """Creates a Git hook that calls a script with certain arguments."""
41 def _stdin_args_for_hook(hook) -> Sequence[str]: argument
42 """Gives stdin arguments for each hook.
46 if hook == 'pre-push':
53 if hook in ('pre-receive', 'post-receive', 'reference-transaction'):
55 if hook == 'post-rewrite':
67 hook: str,
71 """Installs a simple Git hook that executes the provided command.
74 hook: Git hook to install, e.g. 'pre-push'.
75 command: Command to execute as the hook. The command is executed from the
[all …]
/external/rust/android-crates-io/crates/libbpf-rs/src/
Dtc.rs39 /// As such a BPF program using a TC Hook (`SEC("classifier")` or `SEC("tc")`) must be operated
52 hook: libbpf_sys::bpf_tc_hook, field
61 hook: libbpf_sys::bpf_tc_hook::default(), in new()
65 tc_hook.hook.sz = size_of::<libbpf_sys::bpf_tc_hook>() as libbpf_sys::size_t; in new()
74 /// If a [`TcHook`] already exists with the same parameters as the hook calling
77 /// Will always fail on a `TC_CUSTOM` hook
79 let err = unsafe { libbpf_sys::bpf_tc_hook_create(&mut self.hook as *mut _) }; in create()
82 // the hook may already exist, this is not an error in create()
97 self.hook.ifindex = idx; in ifindex()
105 /// An `TC_EGRESS|TC_INGRESS` hook can be used as an attach point for calling
[all …]
/external/pytorch/test/distributed/algorithms/ddp_comm_hooks/
Dtest_ddp_hooks.py101 # Register DDP Communication Hook if defined
126 This unit test verifies the ``allreduce`` hook registered case gives same result
127 with no hook registered case.
131 # No hook registered case, get the reference grads.
133 # Register hook case, get the hook grads.
142 This unit test verifies the ``fp16 compress`` hook registered case
143 gives close result with no hook registered case.
147 # No hook registered case, get the reference grads.
149 # Register hook case, get the hook grads.
158 This unit test verifies the ``quantize per tensor`` hook registered case
[all …]
/external/python/google-api-python-client/docs/dyn/
Dapigee_v1.organizations.environments.flowhooks.html79 <p class="firstline">Attaches a shared flow to a flow hook.</p>
85 <p class="firstline">Detaches a shared flow from a flow hook.</p>
88 … the shared flow attached to the specified flow hook. If there's no shared flow attached to the fl…
92 <pre>Attaches a shared flow to a flow hook.
95 …name: string, Required. Name of the flow hook to which the shared flow should be attached in the f…
100 …ontinue if the flow hook throws an exception. Set to `true` to continue execution. Set to `false` …
101 &quot;description&quot;: &quot;A String&quot;, # Description of the flow hook.
102 … &quot;A String&quot;, # Output only. Where in the API call flow the flow hook is invoked. Must be…
103 …&quot;sharedFlow&quot;: &quot;A String&quot;, # Shared flow attached to this flow hook, or empty i…
115 …ontinue if the flow hook throws an exception. Set to `true` to continue execution. Set to `false` …
[all …]
/external/pdfium/third_party/abseil-cpp/absl/base/internal/
Dmalloc_hook.h27 // There are a limited number of slots available for each hook type. Add*Hook
28 // will return false if there are no slots available. Remove*Hook will return
29 // false if the given hook was not already installed.
31 // The order in which individual hooks are called in Invoke*Hook is undefined.
33 // It is safe for a hook to remove itself within Invoke*Hook and add other
34 // hooks. Any hooks added inside a hook invocation (for the same hook type)
44 // Note: the Invoke*Hook() functions are defined in malloc_hook-inl.h. If you
45 // need to invoke a hook (which you shouldn't unless you're part of tcmalloc),
68 // Enum for recording the section to which the frame with hook belongs to.
77 // Enum to control how a hook can access the memory.
[all …]
/external/python/cpython3/Modules/_testcapi/
Dmem.c21 alloc_hook_t *hook = (alloc_hook_t *)ctx; in hook_malloc() local
22 hook->ctx = ctx; in hook_malloc()
23 hook->malloc_size = size; in hook_malloc()
24 return hook->alloc.malloc(hook->alloc.ctx, size); in hook_malloc()
30 alloc_hook_t *hook = (alloc_hook_t *)ctx; in hook_calloc() local
31 hook->ctx = ctx; in hook_calloc()
32 hook->calloc_nelem = nelem; in hook_calloc()
33 hook->calloc_elsize = elsize; in hook_calloc()
34 return hook->alloc.calloc(hook->alloc.ctx, nelem, elsize); in hook_calloc()
40 alloc_hook_t *hook = (alloc_hook_t *)ctx; in hook_realloc() local
[all …]
/external/elfutils/backends/
Dppc64_init.c51 HOOK (eh, reloc_simple_type); in ppc64_init()
52 HOOK (eh, dynamic_tag_name); in ppc64_init()
53 HOOK (eh, dynamic_tag_check); in ppc64_init()
54 HOOK (eh, machine_flag_check); in ppc64_init()
55 HOOK (eh, copy_reloc_p); in ppc64_init()
56 HOOK (eh, check_special_symbol); in ppc64_init()
57 HOOK (eh, check_st_other_bits); in ppc64_init()
58 HOOK (eh, bss_plt_p); in ppc64_init()
59 HOOK (eh, return_value_location); in ppc64_init()
60 HOOK (eh, register_info); in ppc64_init()
[all …]
Darm_init.c49 HOOK (eh, segment_type_name); in arm_init()
50 HOOK (eh, section_type_name); in arm_init()
51 HOOK (eh, machine_flag_check); in arm_init()
52 HOOK (eh, reloc_simple_type); in arm_init()
53 HOOK (eh, register_info); in arm_init()
54 HOOK (eh, core_note); in arm_init()
55 HOOK (eh, auxv_info); in arm_init()
56 HOOK (eh, check_object_attribute); in arm_init()
57 HOOK (eh, return_value_location); in arm_init()
58 HOOK (eh, abi_cfi); in arm_init()
[all …]
Dppc_init.c49 HOOK (eh, reloc_simple_type); in ppc_init()
50 HOOK (eh, machine_flag_check); in ppc_init()
51 HOOK (eh, dynamic_tag_name); in ppc_init()
52 HOOK (eh, dynamic_tag_check); in ppc_init()
53 HOOK (eh, check_special_symbol); in ppc_init()
54 HOOK (eh, bss_plt_p); in ppc_init()
55 HOOK (eh, return_value_location); in ppc_init()
56 HOOK (eh, register_info); in ppc_init()
57 HOOK (eh, core_note); in ppc_init()
58 HOOK (eh, auxv_info); in ppc_init()
[all …]
/external/rust/android-crates-io/crates/grpcio-sys/grpc/third_party/abseil-cpp/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/angle/third_party/abseil-cpp/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/abseil-cpp/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/openscreen/third_party/abseil/src/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/cronet/tot/third_party/abseil-cpp/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/cronet/stable/third_party/abseil-cpp/absl/base/internal/
Datomic_hook_test.cc32 hook; in TEST() local
36 EXPECT_TRUE(hook.Load() == nullptr); in TEST()
38 hook(1); in TEST()
41 // Test a stored hook. in TEST()
42 hook.Store(TestHook); in TEST()
43 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
45 hook(1); in TEST()
48 // Calling Store() with the same hook should not crash. in TEST()
49 hook.Store(TestHook); in TEST()
50 EXPECT_TRUE(hook.Load() == TestHook); in TEST()
[all …]
/external/pytorch/torch/nn/modules/
Dmodule.py83 def __init__(self, hook: Callable, module: Optional["Module"] = None):
84 self.hook: Callable = hook
85 functools.update_wrapper(self, hook)
97 raise RuntimeError("You are trying to call the hook of a dead Module!")
98 return self.hook(module, *args, **kwargs)
99 return self.hook(*args, **kwargs)
102 result = {"hook": self.hook, "with_module": self.with_module}
109 self.hook = state["hook"]
115 "You are trying to revive the hook of a dead Module!"
134 hook: Callable[..., None],
[all …]
/external/pytorch/torch/optim/
Doptimizer.py271 def register_optimizer_step_pre_hook(hook: GlobalOptimizerPreHook) -> RemovableHandle:
272 r"""Register a pre hook common to all optimizers.
274 The hook should have the following signature::
276 hook(optimizer, args, kwargs) -> None or modified args and kwargs
279 hook (Callable): A user defined hook which is registered on all optimizers.
283 a handle that can be used to remove the added hook by calling
287 _global_optimizer_pre_hooks[handle.id] = hook
291 def register_optimizer_step_post_hook(hook: GlobalOptimizerPostHook) -> RemovableHandle:
292 r"""Register a post hook common to all optimizers.
294 The hook should have the following signature::
[all …]
/external/cldr/common/transforms/
DAny-Accents.xml65 # $pre XXX $post ↔ ̉ ; # COMBINING HOOK ABOVE
98 # $pre YYY $post ↔ Ɓ ; # LATIN CAPITAL LETTER B WITH HOOK
103 # $pre YYY $post ↔ Ƈ ; # LATIN CAPITAL LETTER C WITH HOOK
104 # $pre YYY $post ↔ ƈ ; # LATIN SMALL LETTER C WITH HOOK
106 # $pre YYY $post ↔ Ɗ ; # LATIN CAPITAL LETTER D WITH HOOK
111 # $pre YYY $post ↔ Ƒ ; # LATIN CAPITAL LETTER F WITH HOOK
112 # $pre YYY $post ↔ ƒ ; # LATIN SMALL LETTER F WITH HOOK
113 # $pre YYY $post ↔ Ɠ ; # LATIN CAPITAL LETTER G WITH HOOK
118 # $pre YYY $post ↔ Ƙ ; # LATIN CAPITAL LETTER K WITH HOOK
119 # $pre YYY $post ↔ ƙ ; # LATIN SMALL LETTER K WITH HOOK
[all …]
/external/icu/icu4c/source/data/translit/
DAny_Accents.txt61 # $pre XXX $post ↔ \u0309 ; # COMBINING HOOK ABOVE
94 # $pre YYY $post ↔ Ɓ ; # LATIN CAPITAL LETTER B WITH HOOK
99 # $pre YYY $post ↔ Ƈ ; # LATIN CAPITAL LETTER C WITH HOOK
100 # $pre YYY $post ↔ ƈ ; # LATIN SMALL LETTER C WITH HOOK
102 # $pre YYY $post ↔ Ɗ ; # LATIN CAPITAL LETTER D WITH HOOK
107 # $pre YYY $post ↔ Ƒ ; # LATIN CAPITAL LETTER F WITH HOOK
108 # $pre YYY $post ↔ ƒ ; # LATIN SMALL LETTER F WITH HOOK
109 # $pre YYY $post ↔ Ɠ ; # LATIN CAPITAL LETTER G WITH HOOK
114 # $pre YYY $post ↔ Ƙ ; # LATIN CAPITAL LETTER K WITH HOOK
115 # $pre YYY $post ↔ ƙ ; # LATIN SMALL LETTER K WITH HOOK
[all …]
/external/cronet/tot/third_party/icu/source/data/translit/
DAny_Accents.txt61 # $pre XXX $post ↔ \u0309 ; # COMBINING HOOK ABOVE
94 # $pre YYY $post ↔ Ɓ ; # LATIN CAPITAL LETTER B WITH HOOK
99 # $pre YYY $post ↔ Ƈ ; # LATIN CAPITAL LETTER C WITH HOOK
100 # $pre YYY $post ↔ ƈ ; # LATIN SMALL LETTER C WITH HOOK
102 # $pre YYY $post ↔ Ɗ ; # LATIN CAPITAL LETTER D WITH HOOK
107 # $pre YYY $post ↔ Ƒ ; # LATIN CAPITAL LETTER F WITH HOOK
108 # $pre YYY $post ↔ ƒ ; # LATIN SMALL LETTER F WITH HOOK
109 # $pre YYY $post ↔ Ɠ ; # LATIN CAPITAL LETTER G WITH HOOK
114 # $pre YYY $post ↔ Ƙ ; # LATIN CAPITAL LETTER K WITH HOOK
115 # $pre YYY $post ↔ ƙ ; # LATIN SMALL LETTER K WITH HOOK
[all …]
/external/cronet/stable/third_party/icu/source/data/translit/
DAny_Accents.txt61 # $pre XXX $post ↔ \u0309 ; # COMBINING HOOK ABOVE
94 # $pre YYY $post ↔ Ɓ ; # LATIN CAPITAL LETTER B WITH HOOK
99 # $pre YYY $post ↔ Ƈ ; # LATIN CAPITAL LETTER C WITH HOOK
100 # $pre YYY $post ↔ ƈ ; # LATIN SMALL LETTER C WITH HOOK
102 # $pre YYY $post ↔ Ɗ ; # LATIN CAPITAL LETTER D WITH HOOK
107 # $pre YYY $post ↔ Ƒ ; # LATIN CAPITAL LETTER F WITH HOOK
108 # $pre YYY $post ↔ ƒ ; # LATIN SMALL LETTER F WITH HOOK
109 # $pre YYY $post ↔ Ɠ ; # LATIN CAPITAL LETTER G WITH HOOK
114 # $pre YYY $post ↔ Ƙ ; # LATIN CAPITAL LETTER K WITH HOOK
115 # $pre YYY $post ↔ ƙ ; # LATIN SMALL LETTER K WITH HOOK
[all …]

12345678910>>...119