דלג לתוכן הראשי
היכנס דרך Microsoft
היכנס או צור חשבון.
שלום,
בחר חשבון אחר.
יש לך חשבונות מרובים
בחר את החשבון שברצונך להיכנס באמצעותו.

מאמר זה מתאר חבילת התיקון החם עבור Microsoft Visual Studio 2015 עדכון 3. התיקון החם מכיל כמה תיקונים ממטב Visual C++ ומחולל קוד (c2.dll). לקבלת מידע נוסף, ראה סעיף "בעיות אשר המתוקנים בתיקון חם זה".

פתרון

כיצד להשיג את התיקון החם

הקובץ הבא זמין להורדה במרכז ההורדות של Microsoft:

Download הורד כעת את חבילת התיקון החם.

לקבלת מידע נוסף אודות אופן ההורדה של קובצי תמיכה של Microsoft, לחץ על מספר המאמר הבא כדי להציג את המאמר הרלוונטי מתוך Microsoft Knowledge Base:

119591 כיצד לקבל קבצי תמיכה של Microsoft משירותים מקווניםMicrosoft סרקה קובץ זה לאיתור וירוסים. Microsoft השתמשה בתוכנת איתור הווירוסים העדכנית ביותר שהיתה זמינה בתאריך פרסום הקובץ. הקובץ מאוחסן בשרתים בעלי אבטחה מוגברת המסייעים למנוע שינויים בלתי מורשים בקובץ.

דרישות מוקדמות

כדי להחיל תיקון חם זה, יש ברשותך Visual Studio 2015 עדכון 3 מותקן.

דרישת הפעלה מחדש

ייתכן שיהיה עליך להפעיל מחדש את המחשב לאחר החלת תיקון חם זה אם אין מופע של Visual Studio נמצא בשימוש.

מידע על החלפת התיקון החם

תיקון חם זה אינו מחליף תיקונים חמים אחרים.

הבעיות המתוקנות באוסף התיקון החם

תיקון חם זה מכיל תיקונים עבור הבעיות הבאות:

  • מתקן באג ב'ממטב בעת hoisting חנות מותנה משתנה הלולאה מחוץ לולאה: #include <cstdlib> #include <cassert> struct Foo { int a; int b; }; int main() { Foo foo; foo.b = rand(); int a = rand(); int b = foo.b; for (int i = 0; i < 10; ++i) { int inner_b = b; int inner_a = a; if (inner_b < 0) // This gets incorrect hoisted outside the loop. // A workaround is /d2SSAOptimizer- { inner_a = 0; inner_b = 0; } if (inner_b >= 0) assert(inner_a == a); a += b; } return 0; }

     

  • תיקון עבור באג חטיבה מספר שלם ממטב: #include <stdio.h> volatile int z = 0; int main() { unsigned a, b; __int64 c; a = z; c = a; c = (c == 0) ? 1LL : c; b = (unsigned)((__int64)a * 100 / c); // Division was made unconditional // incorrectly creating a divide by zero. // A workaround is /d2SSAOptimizer- printf("%u\n", b); return 0; }

     

  • תיקון עבור באג חטיבה מספר שלם ממטב: int checkchecksum(int suly, int ell, int utkodert) { int x; ell -= utkodert; ell %= 103; if (suly - 1) utkodert /= (suly - 1); // Division was made unconditional, // incorrectly creating a potential divide by zero // A workaround is /d2SSAOptimizer- return utkodert; }

     

  • תיקון עבור באג חטיבה מספר שלם ממטב: typedef int unsigned uint; volatile uint out_index = 0; bool data[1] = {true}; bool __declspec(noinline) BugSSA(uint index) { uint group = index / 3; if (group == 0) // The division result being compared to zero is replaced // with a range check. We then incorrectly move the division { // to the next use of "group", without accounting for the fact // that "index" has changed. A workaround is /d2SSAOptimizer- return false; } index -= 3; group--; bool ret = data[group]; // crash here out_index = index; out_index = index; return ret; } int main() { volatile uint i = 3; return BugSSA(i); }

     

  • תקן עבור קריסת ב'ממטב לחלוקה של MIN_INT על-ידי-1: int test_div(bool flag, int dummy) { int result = std::numeric_limits<int>::min(); int other; if (flag) other = -1; else other = dummy - 1 - dummy; result /= other; // We would push the division up into both arms of the // if-then-else. One of those divisions would cause the // optimizer to evaluate MIN_INT/-1.This is a crash, similar // to dividing by zero. A workaround is /d2SSAOptimizer- return result; }

     

  • מתקן לגלישת מחסנית ב'ממטב: #include <stdio.h> // This example produced a stack overflow in the optimizer, which was // caused by mutually-recursive analysis functions not properly tracking // the number of times they were invocated. // A workaround is /d2SSAOptimizer- typedef unsigned char byte; typedef unsigned long long int uint64; int main() { const uint64 *sieveData = new uint64[1024]; uint64 bitIndexShift = 0; uint64 curSieveChunk = 0xfafd7bbef7ffffffULL & ~uint64(3); const unsigned int *NumbersCoprimeToModulo = new unsigned int[16]; const unsigned int *PossiblePrimesForModuloPtr = NumbersCoprimeToModulo; while (!curSieveChunk) { curSieveChunk = *(sieveData++); const uint64 NewValues = (16 << 8) | (32 << 24); bitIndexShift = (NewValues >> (bitIndexShift + 8)) & 255; PossiblePrimesForModuloPtr = NumbersCoprimeToModulo + bitIndexShift; } if (PossiblePrimesForModuloPtr - NumbersCoprimeToModulo != 0) { printf("fail"); return 1; } printf("pass"); return 0; }

     

  • תקן עבור הפקת קוד שגויה בעת הסרת עודפים צף נקודת המרות מעורבת להמיר פרמטר int32 f64: #include <string> __declspec(noinline) void test(int Val) { double Val2 = Val; std::string Str; printf("%lld\n", __int64(Val2)); // We incorrectly try to read 64 bits of // floating point from the parameter area, // instead of reading 32 bits of integer // and converting it. A workaround is // to throw /d2SSAOptimizer- } int main() { test(6); test(7); return 0; }

     

  • מתקן קריסה ב'ממטב בעת פיצול צמתי גרף זרימה במשפט ברירת המחדל של בלוק מתג, לקבלת פרטים נוספים, ראה https://bugs.chromium.org/p/chromium/issues/detail?id=627216#c15.

  • מתקן באג ב'ממטב לולאה בהם אנו לבצע הפחתת עוצמת שגוי של משתני השראה משני לא חתום שהם כפולות של המשתנה השראה ראשי: #include <assert.h> #include <malloc.h> #include <stdio.h> typedef unsigned int uint; typedef unsigned char byte; /* There is a corner case in the compiler's loop optimizer. The corner case arose if an induction variable (IV) is a multiple of the loop index, and there's a comparison of the IV to an integer that is less than this multiplication factor. A workaround is to use #pragma optimize("", off) / #pragma optimize("", on) around the affected function. */ int main(int argc, char *argv[]) { const uint w = 256; const uint h = 64; const uint w_new = w >> 1; const uint h_new = h >> 1; const byte *const src = (byte *)malloc(w * h); byte *it_out = (byte *)malloc(w_new * h_new); int fail = 0; for (uint y_new = 0; y_new < h_new; ++y_new) { for (uint x_new = 0; x_new < w_new; ++x_new, ++it_out) { uint x = x_new * 2; uint y = y_new * 2; if (x < 1 || y < 1) { *it_out = 0; continue; } if (x != 0) { } else { fail = 1; } *it_out = 4 * src[y * w + x]; } } if (fail) { printf("fail\n"); return (1); } printf("pass\n"); return (0); }

     

  • מציע דרך לעקיפת הבעיה עבור C4883 ": גודל פונקציה העלמת מיטובי". כאשר ממטב רואה פונקציות שהן מסיבית, היא תשנה את קנה המידה בחזרה מיטובי המבצע אותה. אותה מנפיקים אזהרה C4883 כאשר הוא עושה זאת, אם הפכת את האזהרה באמצעות /we4883. אם ברצונך לעקוף החלטה זו כדי להעלים מיטוב, להתריע על הבורר /d2OptimizeHugeFunctions.

  • מתקן עבור קריסת מהדר ב- c2! PpCanPropagateForward בעת ביצוע מיטוב על x64.

  • תיקונים עבור לולאה ממטב באגים אשר כוללות הפחתת עוצמת משתנה השראה שגוי.

  • מתקן עבור סידור מחדש של שגוי של ביטויים אשר כרוכות קריאות & כותב זיכרון עקב בדיקת כינוי שגוי.

  • מתקן באג המקצה אוגר וכרוכה שנוצרו על-ידי קומפיילר זמניים קיימים על-פני מספר בחריגים אזורים.

מצב

Microsoft אישרה כי מדובר בבעיה במוצרי Microsoft הרשומים במקטע 'חל על'.

זקוק לעזרה נוספת?

מעוניין באפשרויות נוספות?

גלה את יתרונות המנוי, עיין בקורסי הדרכה, למד כיצד לאבטח את המכשיר שלך ועוד.

קהילות עוזרות לך לשאול שאלות ולהשיב עליהן, לתת משוב ולשמוע ממומחים בעלי ידע עשיר.

האם מידע זה היה שימושי?

עד כמה אתם מרוצים מאיכות השפה?
מה השפיע על החוויה שלך?
בלחיצה על 'שלח', אתה מאפשר למשוב שלך לשפר מוצרים ושירותים של Microsoft. מנהל ה-IT שלך יוכל לאסוף נתונים אלה. הצהרת הפרטיות.

תודה על המשוב!

×