microsoft / microsoft/vscode-cpptools

Debug ends only in disassembly view

Open
#11,587 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

debugger help wanted
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Environment
  • OS and version: Gentoo Linux x64 6.1.57-gentoo-dist also tested on Arch linux
  • VS Code:
    Version: 1.83.1
    Commit: f1b07bd25dfad64b0167beb15359ae573aecd2cc
    Date: 2023-10-10T23:45:31.402Z
    Electron: 25.8.4
    ElectronBuildId: 24154031
    Chromium: 114.0.5735.289
    Node.js: 18.15.0
    V8: 11.4.183.29-electron.0
  • C/C++ extension:v1.17.5
  • GDB / LLDB version: GNU gdb (Gentoo 13.2 vanilla) 13.2
Bug Summary and Steps to Reproduce

Bug Summary:
I'm getting error: Unable to step next. Operation failed with error code 0x80004004 and debug can't end if I debugging not in dissasembly view.

Steps to reproduce:

  1. take default configuration for debug hello world on c
  2. start debug
  3. press f10 untill get error or end of debug.
Debugger Configurations
lauch.json 
{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
    {
        "name": "(gdb) Launch",
        "type": "cppdbg",
        "request": "launch",
        "program": "${workspaceFolder}/${fileBasenameNoExtension}",
        "MIMode": "gdb",
        "cwd": "${workspaceFolder}",
        "stopAtEntry": false,
        "logging": { "engineLogging": true, "trace": true, "traceResponse": true },
        "setupCommands": [
            {
                "description": "Enable pretty-printing for gdb",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            },
            {
                "description": "Set Disassembly Flavor to Intel",
                "text": "-gdb-set disassembly-flavor intel",
                "ignoreFailures": true
            }
        ],
        "preLaunchTask": "C/C++: gcc build active file",
    }
    ],

}

tasks.json 
{
    "tasks": [
        {
            "type": "cppbuild",
            "label": "C/C++: gcc build active file",
            "command": "/usr/bin/gcc",
            "args": [
                "-fdiagnostics-color=always",
                "-g",
                "${file}",
                "-o",
                "${fileDirname}/${fileBasenameNoExtension}"
            ],
            "options": {
                "cwd": "${fileDirname}"
            },
            "problemMatcher": [
                "$gcc"
            ],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "detail": "Task generated by Debugger."
        }
    ],
    "version": "2.0.0"
}
Debugger Logs
too long. Check files
Other Extensions

No other extensions

Additional Information

https://github.com/microsoft/vscode-cpptools/assets/95098167/4b6c8c86-4c94-4308-954d-f055033dff13

default_debug.txt
with_asm_view.txt

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the default C launch configuration from launch.json and tasks.json, stepping with F10 until the failure occurs. Compare default_debug.txt with with_asm_view.txt and inspect the reported behavior when ending debug outside the disassembly view. Done means stepping and ending a debug session work reliably without the 0x80004004 error.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, cpp, vscode
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.