TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Making Windows Slower Part 2: Process Creation

179 点作者 nikbackm超过 6 年前

8 条评论

copper_think超过 6 年前
Application Verifier is a feature of Windows for developers to use to check program correctness. Bruce says he turned on Full Page Heap, which makes every allocation go on a separate page, and tries to line it up so that the next page is not readable or writable. The idea is, if you go past the end of your memory allocation, the CPU raises a protection fault, and you catch the memory corruption bug at its source. Application Verifier can also do other things, like raise an error if your program ever passes an invalid HANDLE to a Windows system call.<p>Application Verifier is turned on by process name (i.e. &quot;explorer.exe&quot;). I think most of the time, developers turn on an Application Verifier feature, start just one process by that name, and then verify. But Bruce turned it on for a short-lived process that runs in a large build. So it runs thousands of times, and he hit this problem. It sounds like a great thing to fix, but I don&#x27;t think it affects most developers using Application Verifier, and it definitely doesn&#x27;t affect &#x27;normal people&#x27; who are just using Windows on their laptop or desktop.
评论 #18230453 未加载
strmpnk超过 6 年前
This reminds me of the Accidentally Quadratic series: <a href="https:&#x2F;&#x2F;accidentallyquadratic.tumblr.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;accidentallyquadratic.tumblr.com&#x2F;</a><p>These issues are quite common and seem to grow out of that initial expectation that N stays small which later turns out to not be so true for cases discovered later on. Scrolling through some of the latest entries, even Chrome itself had some accidentally quadratic complexity.
评论 #18230476 未加载
eitland超过 6 年前
The thing that made the biggest difference for me when it came to experienced slowness was more or less always created by OEMs.<p>Bundled 3rd-party bloatware is one thing, but often the problem would be the actual drivers or utilities that came with the machine.<p>&quot;Utilities&quot; could usually be removed, but if the drivers are bad there wasn&#x27;t much to to except try an older or newer release.<p>The second biggest problem was mandatory antivirus software installed by IT departments. (That is, on my machine. For a lot of people a bigger problem was adware and spyware.)<p>For the benefit of those who are younger than me: Reinstalling stock Windows used to be standard procedure.<p>Today the situation feels a lot better but I still prefer Linnux.
Klathmon超过 6 年前
Microsoft really needs to solve or at least mitigate these issues.<p>I&#x27;ve been using Windows as my main development environment for mainly JavaScript and Python for like 5 years now, and I&#x27;ve felt every single one of these pain points (if you haven&#x27;t, go read parts 0 and 1 of the same series! They are great!).<p>Some of them I&#x27;ve tried to mitigate (I&#x27;ll be looking over my suite of tools to see if any &quot;file watchers&quot; are causing issues now, as well as using the fantastic looking tool from the article to dive into this slowness I feel), but for the most part it&#x27;s just a cost of working on Windows for me, and it&#x27;s pushing me away.<p>With a fraction of the power, I can get magnitudes more &quot;perceived performance&quot; out of Linux or MacOS, and I&#x27;m now starting to use linux VMs more to get that performance back (which is such a weird sentence!)<p>There are things about Linux that I hate as a desktop OS (for me they always seem to &quot;deteriorate&quot; over like 6 months and need a reinstall to stay stable, and I&#x27;ve on more than 5 occasions installed something and restarted only to find the machine unbootable...), and there&#x27;s things I hate about MacOS (the keyboards, the hardware requirements, being linux-ey enough that it feels familiar, but not enough that stuff just works for me), but I can&#x27;t deny that when I work in those OSs, I&#x27;m more productive and spend less time waiting for my machine to do little tasks, and therefore have much less aversion to them (at this point I&#x27;ve almost developed a phobia of having to move, copy, or rename large numbers of files on Windows, and it shows as a lack of organization in projects because of how flakey and time consuming it can be).<p>I know it won&#x27;t be easy, but MS is going to start losing devs and eventually users if this keeps up and the other OSs keep pulling ahead in percevied performance.<p>(As an aside, and just to jump the gun a bit with the expected replies, I&#x27;m fairly certain my Linux-as-a-desktop-os issues are self inflicted or come from a lack of understanding of something on my part, but I haven&#x27;t had the time to dive into what they are, and a slow OS is better than a non-functional one. Hopefully my increased usage of VMs now will iron out those issues without as much risk)
评论 #18229565 未加载
评论 #18229534 未加载
评论 #18229328 未加载
gwern超过 6 年前
&gt; Microsoft could fix this problem by using something other than a monotonically increasing log-file number. If they used the current date and time (to millisecond or higher resolution) as part of the file name then they would get log file names that were more semantically meaningful, and could be created extremely quickly with virtually no unique-file-search logic.<p>Does Windows have no equivalent of `mktemp`? Getting unique identifiers is a common requirement.
评论 #18230901 未加载
评论 #18230809 未加载
Forge36超过 6 年前
I&#x27;ve definitely seen this practice, the solution I saw to &quot;fix&quot; this: after 20 attempts fail. Silently. It was a static file, but it didn&#x27;t track last file created (of course someone had copied this static file... But that&#x27;s a separate problem).
评论 #18229135 未加载
hyperman1超过 6 年前
I&#x27;m starting to get the same kind of vibes as with Mark russinovich&#x27;s sysinternals &#x27;the case of the ....&#x27; blog posts. Same investigative style. The blog is unabashedly technical, hands on, and yet crystal clear.
mjevans超过 6 年前
The other two blog posts linked at the top are also entertaining and educational reading.<p><pre><code> Making Windows Slower Part 0: Making VirtualAlloc arbitrarily slower Making Windows Slower Part 1: Making file access slower</code></pre>