::: µ¨ÆÄÀÌ Tip&Trick :::

µ¨ÆÄÀÌ Tip&Trick ¼º°Ý¿¡ ¸ÂÁö ¾Ê´Â ±¤°í,ºñ¹æ,Áú¹®ÀÇ ±ÛÀº Áï½Ã »èÁ¦Çϸç
³»¿ëÀ» º¹»çÇÏ¿© »ç¿ëÇÒ °æ¿ì ¹Ýµå½Ã À̰÷(http://www.howto.pe.kr)À» Ãâó·Î ¸í½ÃÇÏ¿© ÁÖ¼¼¿ä


Category

  ±è¿µ´ë(2005-09-13 22:50:56, Hit : 5830, Vote : 1391
 http://www.howto.pe.kr
 CPU À̸§ ±¸Çϱâ2

unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TForm1 = class(TForm)
    Button1: TButton;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

function GetBrandString : string;
    function CPUIDAvail : boolean; assembler;
    {Thests wheter the CPUID instruction is available}
    asm
      pushfd                // get flags into ax
      pop   eax             // save a copy on the stack
      mov   edx,eax
      xor   eax, 0200000h   // flip bit 21
      push  eax             // load new value into flags
      popfd                 // get them back
      pushfd
      pop   eax
      xor   eax,edx
      and   eax, 0200000h   // clear all but bit 21
      shr   eax, 21
    end;
const
  CPUID=$a20f;
var
  s:array[0..48] of char;
begin
  fillchar(s,sizeof(s),0);
  if CPUIDAvail then begin
    asm
      //save regs
      push ebx
      push ecx
      push edx
      //check if necessary extended CPUID calls are
      //supported, if not return null string
      mov  eax,080000000h
      {dw}   CPUID
      cmp  eax,080000004h
      jb   @@endbrandstr
      //get first name part
      mov  eax,080000002h
      {dw}   CPUID
      mov  longword(s[0]),eax
      mov  longword(s[4]),ebx
      mov  longword(s[8]),ecx
      mov  longword(s[12]),edx
      //get second name part
      mov  eax,080000003h
      {dw}   CPUID
      mov  longword(s[16]),eax
      mov  longword(s[20]),ebx
      mov  longword(s[24]),ecx
      mov  longword(s[28]),edx
      //get third name part
      mov  eax,080000004h
      {dw}   CPUID
      mov  longword(s[32]),eax
      mov  longword(s[36]),ebx
      mov  longword(s[40]),ecx
      mov  longword(s[44]),edx
    @@endbrandstr:
      //restore regs
      pop  edx
      pop  ecx
      pop  ebx
     end;
   end;
   result:=StrPas(s);
end;

procedure TForm1.Button1Click(Sender: TObject);
begin
  ShowMessage(GetBrandString);
end;

end.





971   [À©µµ¿ìÁî API] ÀÛ¾÷ Ç¥½ÃÁÙ¿¡ º¸ÀÌ´Â ÇÁ·Î±×·¥ÀÇ ¾ÆÀÌÄÜ Á¤º¸  ±è¿µ´ë 2008/12/09 6375 1484
970   [À©µµ¿ìÁî API] ½ÇÇà ÆÄÀÏÀÇ ¾ÆÀÌÄÜ ¹Ù²Ù±â  ±è¿µ´ë 2008/11/27 7840 1445
969   [³×Æ®¿÷/ÀÎÅͳÝ] TClientSocket ¿¡ Local IP ¹ÙÀεùÇÏ±â  ±è¿µ´ë 2008/11/25 6628 1550
968   [¾Ë°í¸®Áò] Boyer-Moore-Horspool Text Searching  ±è¿µ´ë 2008/11/24 5177 1387
967   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] Tab, Shift+Tab Ű À̺¥Æ® »ç¿ëÇÏ±â  ±è¿µ´ë 2008/11/21 5191 1432
966   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] TStringList vs. THashedStringList  ±è¿µ´ë 2008/11/04 5422 1409
965   [½Ã½ºÅÛ] ÇÁ·Î¼¼½º°¡ ¿øµµ¿ìÁî ¿ø°Ý Å͹̳ο¡¼­ ½ÇÇàÁßÀÎÁö °Ë»ç  ±è¿µ´ë 2008/11/04 5376 1520
964   [½Ã½ºÅÛ] ¿øµµ¿ìÁî µµ¸ÞÀÎ À̸§ ±¸ÇÏ±â  ±è¿µ´ë 2008/11/04 12438 1403
963   [½Ã½ºÅÛ] »ç¿ëÁßÀÎ USB Æ÷Æ®ÀÇ ÀåÄ¡Á¤º¸ ±¸ÇÏ±â  ±è¿µ´ë 2008/11/04 18500 1518
962   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] TreeviewÀÇ ¼öÆò ½ºÅ©·Ñ¹Ù °¨Ãß°í ½ºÅ©·Ñ ¸·±â  ±è¿µ´ë 2006/03/22 5629 1285
961   [À©µµ¿ìÁî API] ¹ÙÅÁÈ­¸éÀÇ ¸ðµç â ÃÖ¼ÒÈ­ÇÏ±â  ±è¿µ´ë 2006/02/28 5582 1342
960   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ÀÏÁ¤½Ã°£ °æ°úÈÄ ¾ø¾îÁö´Â MessageBox  ±è¿µ´ë 2006/02/28 6821 1637
959   [½Ã½ºÅÛ] SystemÀÇ Idle »óŸ¦ ¾Ë¾Æ³»´Â API  ±è¿µ´ë 2006/02/28 6310 1479
958   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ListBox¿¡ Edit ¿Ã·Á Ç׸ñ ÆíÁýÇÏ±â  ±è¿µ´ë 2006/02/28 4947 1245
957   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] Æû Èçµé±â  ±è¿µ´ë 2006/02/28 8035 1231
956   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ¸¶¿ì½º·Î ProgressBarÀÇ Position ¹Ù²Ù±â  ±è¿µ´ë 2006/02/28 4997 1290
955   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ListBox µå·¡±×ÇÏ¿© ¾ÆÀÌÅÛ À̵¿ÇÏ±â  ±è¿µ´ë 2006/02/28 5020 1212
954   [½Ã½ºÅÛ] ÆûÀÇ Move/Resize ½ÃÀÛ,Á¾·á À̺¥Æ® °¨ÁöÇÏ±â  ±è¿µ´ë 2006/02/28 5320 1395
953   [COM/OLE] IEÀÇ ¼Ó¼ºÀ» º¯°æÇÏ¿© ¶Ù¿ì±â  ±è¿µ´ë 2006/02/28 5426 1268
952   [À©µµ¿ìÁî API] ¼¼·Î ±Û²Ã Á¦°ÅÇÑ FontDialog  ±è¿µ´ë 2006/02/28 5349 1385
  [½Ã½ºÅÛ] CPU À̸§ ±¸Çϱâ2  ±è¿µ´ë 2005/09/13 5830 1391
950   [³×Æ®¿÷/ÀÎÅͳÝ] IP Helper API ¸¦ ÀÌ¿ëÇÑ ³×Æ®¿öÅ© Ä«µå Enable/Disable ½ÃŰ±â  ±è¿µ´ë 2005/09/10 6279 1355
949   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] Æû¿¡ ÀÚ¼®È¿°ú ÁÖ±â (Delphi 6 ÀÌÇÏ)  ±è¿µ´ë 2005/08/04 6361 1338
948   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] °´Ã¼ÀÇ valid°Ë»ç Assigned() ´ëü  ±è¿µ´ë 2005/07/29 4888 1276
947   [½Ã½ºÅÛ] ½Ã½ºÅÛ ´ë±â¸ðµå/È­¸é º¸È£±â/¸ð´ÏÅÍ ²ô±â À̺¥Æ® °¨ÁöÇÏ±â  ±è¿µ´ë 2005/07/21 7351 1542
946     [COM/OLE] [re] PDF ActiveX »ç¿ëÇÏ±â  Ãʺ¸µ¨ÇÇ 2005/07/18 4972 1097
945   [½Ã½ºÅÛ] À©µµ¿ìÁî GUI ±âº» ÆùÆ®Á¤º¸ ±¸ÇÏ±â  ±è¿µ´ë 2005/07/14 5626 1386
944   [½Ã½ºÅÛ] À©µµ¿ìÁî ÀԷµµ±¸¸ðÀ½ÀÇ ÇÑ/¿µ Åä±ÛÇÏ±â  ±è¿µ´ë 2005/06/24 5413 1422
943   [COM/OLE] ActiveFormÀÇ OnDestroy ´ë¿ë  ±è¿µ´ë 2005/04/21 5425 1268
942   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ListViewÀÇ Å¸ÀÌÆ² ÆùÆ® ¹Ù²Ù±â  ±è¿µ´ë 2005/03/31 5356 1279
941   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ÀÏÁ¤½Ã°£ °æ°úÈÄ ¾ø¾îÁö´Â MessageDlg/ShowMessage  ±è¿µ´ë 2005/03/26 6019 1306
940   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ÇÁ·Î±×·¥ÀÇ bitmapÀ» MS ±×¸²ÆÇÀ¸·Î ÆíÁýÇÏ¿© ´Ù½Ã ºÒ·¯¿À±â  ±è¿µ´ë 2005/03/22 5362 1367
939   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] RichEdit 2.0 ÁÙ°£°Ý Á¶Á¤  ±è¿µ´ë 2005/02/11 7791 1313
938   [COM/OLE] Ž»ö±â¿¡¼­ ÆÄÀÏÀ» ¼±ÅÃÇÏ¿© ActiveX(ActiveFortm)¿¡ Drag&Drop ÇÏ±â  ±è¿µ´ë 2005/01/06 7791 1308
937   [À©µµ¿ìÁî API] TDownloadURL¸¦ »ç¿ëÇÑ ÆÄÀÏ ´Ù¿î¹Þ±â  ±è¿µ´ë 2004/12/26 6717 1311
936   [COM/OLE] TWebBrowser¿¡ Á÷Á¢ HTML ¼Ò½ºÄÚµå ³Ö±â  ±è¿µ´ë 2004/12/26 6396 1330
935   [À©µµ¿ìÁî API] À©µµ¿ìÁî ½Ã½ºÅÛ Àüü¿¡¼­ »ç¿ëÀÚÀÇ ¸¶¿ì½º¿Í Űº¸µå ÀÔ·ÂÀÌ ÀÖ´ÂÁö °Ë»çÇÏ±â  ±è¿µ´ë 2004/12/26 6253 1394
934   [ÀϹÝ/ÄÄÆ÷³ÍÆ®] ´ÙÀ̾ó·Î±× ¹Ú½º°¡ ÀÌ¹Ì ¶°ÀÖ´ÂÁö °Ë»çÇÏ¿© °­Á¦·Î ´Ý±â  ±è¿µ´ë 2004/12/22 5196 1249
933   [À©µµ¿ìÁî API] URLDownloadToFile()¸¦ »ç¿ëÇÑ ÆÄÀÏ ´Ù¿î¹Þ±â  ±è¿µ´ë 2004/12/15 7968 1434
932   [COM/OLE] ³» ÇÁ·Î±×·¥¿¡¼­ ¼±ÅÃÇÑ text¸¦ ´Ù¸¥ ÇÁ·Î±×·¥¿¡ Drag&DropÀ¸·Î ÁÖ±â  ±è¿µ´ë 2004/12/10 5559 1150

1 [2][3][4][5][6][7][8][9][10]..[25] [´ÙÀ½ 10°³]
 

Copyright 1999-2019 Zeroboard / skin by zero