| /developtools/hdc/src/common/ |
| D | forward.cpp | 46 HCtxForward ctx = iter->second; in StopTask() local 47 ctxs.push_back(ctx); in StopTask() 52 for (auto ctx: ctxs) { in StopTask() local 53 FreeContext(ctx, 0, false); in StopTask() 118 HCtxForward ctx = nullptr; in MallocContext() local 119 if ((ctx = new ContextForward()) == nullptr) { in MallocContext() 122 ctx->id = Base::GetRuntimeMSec(); in MallocContext() 123 ctx->masterSlave = masterSlave; in MallocContext() 124 ctx->thisClass = this; in MallocContext() 125 ctx->fdClass = nullptr; in MallocContext() [all …]
|
| /developtools/profiler/device/base/src/ |
| D | epoll_event_poller.cpp | 47 auto ctx = std::make_shared<EventContext>(); in AddFileDescriptor() local 48 CHECK_NOTNULL(ctx, false, "create EventContext FAILED!"); in AddFileDescriptor() 49 ctx->fd = fd; in AddFileDescriptor() 50 ctx->onReadable = onReadable; in AddFileDescriptor() 51 ctx->onWritable = onWritable; in AddFileDescriptor() 54 CHECK_TRUE(AddContextLocked(ctx), false, "add context for %d failed!", fd); in AddFileDescriptor() 64 auto ctx = it->second; in RemoveFileDescriptor() local 65 CHECK_NOTNULL(ctx, false, "ctx null!"); in RemoveFileDescriptor() 66 CHECK_TRUE(RemoveContextLocked(ctx), false, "remove context for %d failed!", fd); in RemoveFileDescriptor() 70 bool EpollEventPoller::AddContextLocked(const EventContextPtr& ctx) in AddContextLocked() argument [all …]
|
| /developtools/integration_verification/tools/fotff/utils/ |
| D | hdc.go | 23 func WaitHDC(device string, ctx context.Context) bool { 24 ctx, cancelFn := context.WithTimeout(ctx, 20*time.Second) 28 case <-ctx.Done(): 32 ExecContext(ctx, hdc, "kill") 34 ExecContext(ctx, hdc, "start") 36 out, err := ExecCombinedOutputContext(ctx, hdc, "list", "targets") 58 func TryRebootToLoader(device string, ctx context.Context) error { 61 if connected := WaitHDC(device, ctx); connected { 63 return ExecContext(ctx, hdc, "shell", "reboot", "loader") 65 return ExecContext(ctx, hdc, "-t", device, "shell", "reboot", "loader") [all …]
|
| D | exec.go | 29 func ExecContext(ctx context.Context, name string, args ...string) error { 30 ctx, fn := context.WithTimeout(ctx, 6*time.Hour) 32 if err := execContext(ctx, name, args...); err != nil { 37 return execContext(ctx, name, args...) 42 func execContext(ctx context.Context, name string, args ...string) error { 45 cmd := exec.CommandContext(ctx, name, args...) 63 func ExecCombinedOutputContext(ctx context.Context, name string, args ...string) ([]byte, error) { 64 ctx, fn := context.WithTimeout(ctx, 6*time.Hour) 66 out, err := execCombinedOutputContext(ctx, name, args...) 72 return execCombinedOutputContext(ctx, name, args...) [all …]
|
| /developtools/smartperf_host/ide/src/trace/database/ui-worker/ |
| D | ProcedureWorkerFrameSpacing.ts | 164 ctx: CanvasRenderingContext2D, 177 ctx.beginPath(); 178 ctx.lineWidth = 1; 179 ctx.globalAlpha = 1; 180 ctx.arc(currentStruct.frame!.x, currentPointY, multiple, 0, multiple * Math.PI); 181 ctx.strokeStyle = ColorUtils.ANIMATION_COLOR[2]; 182 ctx.fillStyle = ColorUtils.ANIMATION_COLOR[2]; 183 ctx.stroke(); 184 ctx.fill(); 185 ctx.closePath(); [all …]
|
| D | ProcedureWorkerIrq.ts | 98 static draw(ctx: CanvasRenderingContext2D, data: IrqStruct, isHover: boolean) { 100 ctx.fillStyle = ColorUtils.colorForName(data.name || ''); 101 ctx.strokeStyle = '#232c5d'; 103 ctx.lineWidth = 1; 104 ctx.globalAlpha = 0.6; 105 …ctx.fillRect(data.frame.x, data.frame.y + padding, data.frame.width, data.frame.height - padding *… 106 ctx.lineWidth = 2; 107 …ctx.strokeRect(data.frame.x, data.frame.y + padding, data.frame.width - 2, data.frame.height - pad… 109 ctx.globalAlpha = 0.6; 110 ctx.lineWidth = 1; [all …]
|
| D | ProcedureWorkerFrameDynamic.ts | 171 ctx: CanvasRenderingContext2D, 185 ctx.beginPath(); 186 ctx.lineWidth = 1; 187 ctx.globalAlpha = 1; 188 ctx.arc(currDynamic.frame!.x, currDynamic.frame!.y, smallArcRadius, 0, multiple * Math.PI); 189 ctx.strokeStyle = ColorUtils.ANIMATION_COLOR[2]; 190 ctx.fillStyle = ColorUtils.ANIMATION_COLOR[2]; 191 ctx.stroke(); 192 ctx.fill(); 193 ctx.closePath(); [all …]
|
| D | ProcedureWorkerJank.ts | 187 static draw(ctx: CanvasRenderingContext2D, data: JankStruct, nsScale: number): void { 191 ctx.globalAlpha = 1; 192 ctx.fillStyle = ColorUtils.JANK_COLOR[0]; 194 ctx.fillStyle = ColorUtils.JANK_COLOR[2]; 196 ctx.fillStyle = ColorUtils.JANK_COLOR[3]; 206 ctx.globalAlpha = 0.7; 209 this.drawActualFrame(ctx, data, miniHeight); 211 this.drawExpectedFrame(data, nsScale, ctx, miniHeight); 214 ctx.fillStyle = '#fff'; 215 drawString(ctx, `${data.name || ''}`, 5, data.frame, data); [all …]
|
| D | ProduceWorkerSdkSlice.ts | 124 static draw(ctx: CanvasRenderingContext2D, data: SdkSliceStruct) { 128 ctx.fillStyle = '#6DC0DC'; 129 ctx.strokeStyle = '#6DC0DC'; 131 ctx.lineWidth = 1; 132 ctx.fillRect(data.frame.x, data.frame.y + 4, width, data.frame.height - 10); 133 ctx.beginPath(); 134 ctx.arc(data.frame.x, data.frame.y + 4, 3, 0, 2 * Math.PI, true); 135 ctx.fill(); 136 ctx.globalAlpha = 1.0; 137 ctx.stroke(); [all …]
|
| D | ProcedureWorkerHeapSnapshot.ts | 110 static draw(ctx: CanvasRenderingContext2D, data: HeapSnapshotStruct): void { 112 ctx.fillStyle = 'rgb(86,192,197)'; 113 …ctx!.fillRect(data.frame!.x, data.frame!.y + padding, data.frame!.width, data.frame!.height - padd… 115 ctx.globalAlpha = 1.0; 116 ctx.lineWidth = 1; 117 ctx.fillStyle = '#fff'; 118 ctx.textBaseline = 'middle'; 119 ctx.font = '12px sans-serif'; 120 HeapSnapshotStruct.drawString(ctx, data.name || '', 3, data.frame!, data, 4); 121 …HeapSnapshotStruct.drawString(ctx, Utils.getBinaryByteWithUnit(data.size) || '', 9, data.frame!, d… [all …]
|
| D | ProcedureWorkerAllAppStartup.ts | 73 static draw(ctx: CanvasRenderingContext2D, data: AllAppStartupStruct): void { 75 ctx.globalAlpha = 1.0; 76 ctx.fillStyle = ColorUtils.colorForTid(data.startName!); 77 ctx.fillRect(data.frame.x, data.frame.y, data.frame.width, data.frame.height); 79 ctx.textBaseline = 'middle'; 80 ctx.lineWidth = 1; 87 ctx.fillStyle = ColorUtils.funcTextColor(textColor); 88 drawString(ctx, draAppName, 2, data.frame, data); 91 ctx.strokeStyle = '#232c5d'; 92 ctx.lineWidth = 2; [all …]
|
| D | ProcedureWorkerFunc.ts | 184 static draw(ctx: CanvasRenderingContext2D, data: FuncStruct) { 189 ctx.globalAlpha = 1; 190 …ctx.fillStyle = ColorUtils.FUNC_COLOR[ColorUtils.hashFunc(data.funName || '', 0, ColorUtils.FUNC_C… 194 ctx.globalAlpha = 0.7; 196 ctx.fillRect(data.frame.x, data.frame.y, data.frame.width, miniHeight - padding * 2); 198 ctx.strokeStyle = '#fff'; 199 ctx.lineWidth = 1; 200 ctx.strokeRect(data.frame.x, data.frame.y, data.frame.width, miniHeight - padding * 2); 201 ctx.fillStyle = ColorUtils.funcTextColor(textColor); 202 drawString(ctx, `${data.funName || ''}`, 5, data.frame, data); [all …]
|
| D | ProcedureWorkerFrameAnimation.ts | 166 ctx: CanvasRenderingContext2D, 175 ctx.globalAlpha = 1.0; 176 ctx.lineWidth = 1; 177 ctx.lineJoin = 'round'; 178 ctx.fillStyle = ColorUtils.ANIMATION_COLOR[6]; 179 ctx.fillRect(frame.x, frame.y, frame.width, frame.height); 180 ctx.fillStyle = ColorUtils.ANIMATION_COLOR[3]; 181 ctx.textBaseline = 'middle'; 182 ctx.font = '8px sans-serif'; 184 ctx, [all …]
|
| D | ProcedureWorkerAppStartup.ts | 101 static draw(ctx: CanvasRenderingContext2D, data: AppStartupStruct): void { 103 ctx.globalAlpha = 1.0; 104 ctx.fillStyle = ColorUtils.colorForTid(data.startName!); 105 ctx.fillRect(data.frame.x, data.frame.y, data.frame.width, data.frame.height); 107 ctx.textBaseline = 'middle'; 108 ctx.lineWidth = 1; 114 ctx.fillStyle = ColorUtils.funcTextColor(textColor); 115 drawString(ctx, data.stepName, 2, data.frame, data); 118 ctx.strokeStyle = '#232c5d'; 119 ctx.lineWidth = 2; [all …]
|
| /developtools/smartperf_host/ide/src/trace/database/ui-worker/cpu/ |
| D | ProcedureWorkerCpuFreqLimits.ts | 107 static draw(ctx: CanvasRenderingContext2D, data: CpuFreqLimitsStruct, maxFreq: number) { 114 ctx.fillStyle = ColorUtils.colorForTid(index); 115 ctx.strokeStyle = ColorUtils.colorForTid(index); 120 ctx.lineWidth = 1; 121 ctx.globalAlpha = this.minAlpha; 122 this.drawArcLine(ctx, data, drawMaxHeight, drawMaxHeight - drawMinHeight); 123 ctx.globalAlpha = this.maxAlpha; 124 this.drawArcLine(ctx, data, drawMinHeight, drawMinHeight); 126 ctx.globalAlpha = this.minAlpha; 127 ctx.lineWidth = 1; [all …]
|
| D | ProcedureWorkerCPU.ts | 67 ctx: CanvasRenderingContext2D; 89 drawLoadingFrame(req.ctx, cpuFilter, row); 90 req.ctx.beginPath(); 91 req.ctx.font = '11px sans-serif'; 94 CpuStruct.draw(req.ctx, re, req.translateY); 96 req.ctx.closePath(); 99 …drawWakeUp(req.ctx, CpuStruct.wakeupBean, startNS, endNS, totalNS, row.frame, wakeup, currentCpu, … 107 …drawWakeUpList(req.ctx, wake, startNS, endNS, totalNS, row.frame, wakeupListItem, currentCpu, true… 249 static draw(ctx: CanvasRenderingContext2D, data: CpuStruct, translateY: number): void { 255 ctx.globalAlpha = 1; [all …]
|
| D | ProcedureWorkerCpuState.ts | 189 static draw(ctx: CanvasRenderingContext2D, path: Path2D, data: CpuStateStruct) { 192 ctx.font = '11px sans-serif'; 193 ctx.fillStyle = chartColor; 194 ctx.strokeStyle = chartColor; 195 ctx.globalAlpha = 0.6; 198 ctx.lineWidth = 1; 199 ctx.globalAlpha = 1.0; 200 ctx.beginPath(); 201 ctx.arc(data.frame.x, 35 - (data.height || 0), 3, 0, 2 * Math.PI, true); 202 ctx.stroke(); [all …]
|
| /developtools/integration_verification/tools/fotff/rec/ |
| D | fotff.go | 32 ctx context.Context member 76 for _, ctx := range contexts { 77 if ctx.ctx.Value("index").(int) < success { 78 ctx.fn() 84 for _, ctx := range contexts { 85 if ctx.ctx.Value("index").(int) > fail { 86 ctx.fn() 101 ctx, fn := context.WithCancel(context.WithValue(context.TODO(), "index", index)) 102 contexts = append(contexts, cancelCtx{ctx: ctx, fn: fn}) 104 go func(index int, ctx context.Context) { [all …]
|
| /developtools/smartperf_host/ide/src/base-ui/chart/pie/ |
| D | LitChartPie.ts | 145 ctx: CanvasRenderingContext2D | undefined | null; property in LitChartPie 290 this.ctx = this.canvas!.getContext('2d', { alpha: true }); 295 this.ctx?.translate(this.centerX, this.centerY); 349 this.ctx?.translate(this.centerX, this.centerY); 361 let metrics = this.ctx!.measureText(text); 364 this.ctx!.beginPath(); 365 this.ctx!.strokeStyle = dataItem.color!; 366 this.ctx!.fillStyle = '#595959'; 375 this.ctx!.moveTo(x1, y1); 376 this.ctx!.lineTo(x2, y2); [all …]
|
| /developtools/profiler/device/plugins/native_daemon/src/ |
| D | hook_manager.cpp | 209 bool HookManager::HandleHookContext(const std::shared_ptr<HookManagerCtx>& ctx) in HandleHookContext() argument 211 if (ctx == nullptr) { in HandleHookContext() 214 if (ctx->pid > 0) { in HandleHookContext() 215 ctx->smbName = "hooknativesmb_" + std::to_string(ctx->pid); in HandleHookContext() 216 } else if (!ctx->processName.empty()) { in HandleHookContext() 217 ctx->smbName = "hooknativesmb_" + ctx->processName; in HandleHookContext() 220 ctx->pid, ctx->processName.c_str()); in HandleHookContext() 225 …ctx->shareMemoryBlock = ShareMemoryAllocator::GetInstance().CreateMemoryBlockLocal(ctx->smbName, b… in HandleHookContext() 226 …CHECK_TRUE(ctx->shareMemoryBlock != nullptr, false, "CreateMemoryBlockLocal FAIL %s", ctx->smbName… in HandleHookContext() 228 ctx->eventNotifier = EventNotifier::Create(0, EventNotifier::NONBLOCK); in HandleHookContext() [all …]
|
| /developtools/smartperf_host/trace_streamer/src/base/sqlite_ext/ |
| D | sqlite_ext_funcs.cpp | 206 void BuildJson(sqlite3_context* ctx, int32_t argc, sqlite3_value** argv) in BuildJson() argument 211 sqlite3_result_error(ctx, "BuildJson arg number error", -1); in BuildJson() 220 sqlite3_result_error(ctx, "BuildJson: Invalid args", -1); in BuildJson() 229 sqlite3_result_error(ctx, "AppendSqlValueError", -1); in BuildJson() 237 sqlite3_result_blob(ctx, "", 0, nullptr); in BuildJson() 242 sqlite3_result_blob(ctx, data.release(), static_cast<int32_t>(raw.size()), free); in BuildJson() 245 void RepeatedJsonStep(sqlite3_context* ctx, int32_t argc, sqlite3_value** argv) in RepeatedJsonStep() argument 248 auto** jsonBuild = static_cast<JsonBuild**>(sqlite3_aggregate_context(ctx, sizeof(JsonBuild*))); in RepeatedJsonStep() 258 sqlite3_result_error(ctx, "BuildJson: Invalid args", -1); in RepeatedJsonStep() 267 sqlite3_result_error(ctx, "AppendSqlValueError", -1); in RepeatedJsonStep() [all …]
|
| /developtools/profiler/device/services/profiler_service/src/ |
| D | profiler_service.cpp | 145 if (auto ctx = weakCtx.lock(); ctx != nullptr) { in StartPluginSessions() local 146 ctx->StopPluginSessions(); in StartPluginSessions() 309 auto ctx = std::make_shared<SessionContext>(); in CreateSession() local 310 CHECK_POINTER_NOTNULL(ctx, "alloc SessionContext failed!"); in CreateSession() 313 ctx->service = this; in CreateSession() 315 ctx->dataRepeater = dataRepeater; in CreateSession() 318 ctx->traceFileWriter = traceWriter; in CreateSession() 320 ctx->sessionConfig = *sessionConfig; in CreateSession() 321 ctx->pluginNames = std::move(pluginNames); in CreateSession() 322 ctx->pluginConfigs = std::move(pluginConfigs); in CreateSession() [all …]
|
| /developtools/smartperf_host/ide/test/trace/database/ui-worker/ |
| D | ProcedureWorkerThread.test.ts | 37 const ctx = canvas.getContext('2d'); constant 49 expect(ThreadStruct.draw(ctx, data)).toBeUndefined(); 56 const ctx = canvas.getContext('2d'); constant 69 expect(ThreadStruct.draw(ctx, data)).toBeUndefined(); 76 const ctx = canvas.getContext('2d'); constant 89 expect(ThreadStruct.drawThread(ctx, data)).toBeUndefined(); 96 const ctx = canvas.getContext('2d'); constant 109 expect(ThreadStruct.drawThread(ctx, data)).toBeUndefined(); 116 const ctx = canvas.getContext('2d'); constant 129 expect(ThreadStruct.drawThread(ctx, data)).toBeUndefined(); [all …]
|
| /developtools/integration_verification/tools/fotff/pkg/dayu200/ |
| D | flash.go | 35 func (m *Manager) flashDevice(device string, pkg string, ctx context.Context) error { 36 if err := utils.TryRebootToLoader(device, ctx); err != nil { 39 if err := m.flashImages(device, pkg, ctx); err != nil { 43 if connected := utils.WaitHDC(device, ctx); !connected { 52 func (m *Manager) flashImages(device string, pkg string, ctx context.Context) error { 56 data, _ := utils.ExecCombinedOutputContext(ctx, m.FlashTool, "LD") 60 data, _ := utils.ExecCombinedOutputContext(ctx, m.FlashTool, "LD") 65 …if err := utils.ExecContext(ctx, m.FlashTool, "-s", locationID, "UL", filepath.Join(m.Workspace, p… 71 …if err := utils.ExecContext(ctx, m.FlashTool, "-s", locationID, "UL", filepath.Join(m.Workspace, p… 80 …if err := utils.ExecContext(ctx, m.FlashTool, "-s", locationID, "DI", "-p", filepath.Join(m.Worksp… [all …]
|
| /developtools/smartperf_host/ide/test/trace/bean/ |
| D | ThreadStruct.test.ts | 25 const ctx = canvas.getContext('2d'); constant 45 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined(); 50 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined(); 55 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined(); 60 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined(); 65 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined(); 70 expect(ThreadStruct.draw(ctx, dataSource)).toBeUndefined();
|